Mad Fish Elements
HomeTrust CenterData visualization API

Data visualization API

Create organization-scoped reports from standard JSON, render declarative chart configurations, and retrieve saved report data and notes.

API base URLhttps://api.madfishelements.com/api/v1/visualizations
AuthenticationAuthorization: Bearer <MCP API key>
Structured reports from standard JSON

Applications, pipelines, and AI agents can create organization-scoped reports with application/json. The active API key supplies organization and parent-account ownership. An optional user_id assigns the primary user; when omitted, the report is assigned to the user who owns the API key.

Create is idempotent when external_id is reused. Charts use safe declarative option objects, while table, KPI, and dataset widgets cover common non-chart output. Every response is JSON.

Visualization API endpoints6 operations
MethodEndpointPurposeResponse
POST/api/v1/visualizations/reportsCreate a report or upsert by external_id.201 full report
GET/api/v1/visualizations/reportsList report summaries for the organization.200 summaries
GET/api/v1/visualizations/reports/{report_id}Retrieve one complete report.200 full report
PUT / PATCH/api/v1/visualizations/reports/{report_id}Replace the report representation.200 full report
POST / PUT/api/v1/visualizations/reports/{report_id}/widgetsAppend or replace a widget by ID.200 / 201 full report
DELETE/api/v1/visualizations/reports/{report_id}Archive while retaining report data.200 full report

Request conventions

Bearer or API-key header

Send the full active key as Authorization: Bearer <key>. X-API-Key: <key> is also accepted. Missing, expired, revoked, or inactive-organization keys return 401.

JSON bodies and limits

Write operations require a valid JSON object and Content-Type: application/json. Bodies may not exceed 5 MB; reports may contain at most 100 widgets and widget notes may not exceed 20,000 bytes.

Errors

Expect 400 for empty or malformed JSON, 404 for an invalid or out-of-scope report ID, 405 for unsupported methods, 413 for oversized bodies, 422 for schema validation, and 500 when persistence fails.

POST/api/v1/visualizations/reports

Create or upsert a report

Creates a report and returns 201. If the organization already has a report with the same external_id, that report is replaced and keeps its report ID.

Available request fieldsPOST /api/v1/visualizations/reports
FieldTypeRequirementDescription
titleStringRequiredNon-empty report title, maximum 255 characters.
widgetsArrayRequiredNon-empty list containing 1-100 widget objects. Widget IDs must be unique within the report.
user_idIntegerOptional; API key userPrimary active user within the report's parent account. When omitted on create, the API key owner is used; updates retain the existing user.
external_idStringOptional; generatedStable producer ID, maximum 128 characters. Reusing it on POST replaces that organization's existing report.
descriptionStringOptional; emptyReport description, maximum 65,535 bytes.
statusStringOptional; draftOne of draft, published, scheduled, shared, or archived.
date_rangeStringOptional; emptyHuman-readable reporting-period label, maximum 128 characters.
scheduleStringOptional; ManualHuman-readable refresh or delivery label, maximum 64 characters.
layoutObjectOptional; 12 columnsJSON layout configuration. The portal uses columns and gap; default is {"columns":12,"gap":16}.
JSON request bodyreport.json
{
    "external_id": "llm-weekly-revenue",
    "user_id": 198,
    "title": "Weekly Revenue Brief",
    "description": "A weekly revenue report produced by the analytics pipeline.",
    "status": "published",
    "date_range": "Aug 2-8, 2026",
    "schedule": "Every Monday at 08:00 PT",
    "layout": {
        "columns": 12,
        "gap": 16
    },
    "widgets": [
        {
            "id": "revenue-trend",
            "type": "chart",
            "title": "Revenue vs target",
            "width": 8,
            "height": 360,
            "option": {
                "tooltip": {
                    "trigger": "axis"
                },
                "dataset": {
                    "source": [
                        [
                            "day",
                            "Revenue",
                            "Target"
                        ],
                        [
                            "Mon",
                            18400,
                            17000
                        ],
                        [
                            "Tue",
                            21300,
                            18000
                        ]
                    ]
                },
                "xAxis": {
                    "type": "category"
                },
                "yAxis": {},
                "series": [
                    {
                        "type": "bar"
                    },
                    {
                        "type": "line"
                    }
                ]
            },
            "note": "Revenue remained above target."
        }
    ]
}

Send this object as application/json.

JSON response body201 Created
{
    "status": "ok",
    "message": "Report created.",
    "data": {
        "id": "c4e53143da3f4f538ad9bd12",
        "external_id": "llm-weekly-revenue",
        "title": "Weekly Revenue Brief",
        "status": "Published",
        "type": "Data visualization",
        "date_range": "Aug 2-8, 2026",
        "schedule": "Every Monday at 08:00 PT",
        "client_id": 4,
        "user_id": 198,
        "user_label": "Example Customer u00b7 reports@example.com",
        "owner_user_id": 583,
        "updated_at": "2026-08-08 11:42:16",
        "updated_display": "Aug 8, 2026",
        "share_enabled": false,
        "widget_types": [
            "Chart"
        ],
        "description": "A weekly revenue report produced by the analytics pipeline.",
        "layout": {
            "columns": 12,
            "gap": 16
        },
        "source": {
            "external_id": "llm-weekly-revenue",
            "user_id": 198,
            "title": "Weekly Revenue Brief",
            "description": "A weekly revenue report produced by the analytics pipeline.",
            "status": "published",
            "date_range": "Aug 2-8, 2026",
            "schedule": "Every Monday at 08:00 PT",
            "layout": {
                "columns": 12,
                "gap": 16
            },
            "widgets": [
                {
                    "id": "revenue-trend",
                    "type": "chart",
                    "title": "Revenue vs target",
                    "width": 8,
                    "height": 360,
                    "option": {
                        "tooltip": {
                            "trigger": "axis"
                        },
                        "dataset": {
                            "source": [
                                [
                                    "day",
                                    "Revenue",
                                    "Target"
                                ],
                                [
                                    "Mon",
                                    18400,
                                    17000
                                ],
                                [
                                    "Tue",
                                    21300,
                                    18000
                                ]
                            ]
                        },
                        "xAxis": {
                            "type": "category"
                        },
                        "yAxis": {},
                        "series": [
                            {
                                "type": "bar"
                            },
                            {
                                "type": "line"
                            }
                        ]
                    },
                    "note": "Revenue remained above target."
                }
            ]
        },
        "share_url": "",
        "widgets": [
            {
                "id": "revenue-trend",
                "type": "chart",
                "title": "Revenue vs target",
                "width": 8,
                "height": 360,
                "option": {
                    "tooltip": {
                        "trigger": "axis"
                    },
                    "dataset": {
                        "source": [
                            [
                                "day",
                                "Revenue",
                                "Target"
                            ],
                            [
                                "Mon",
                                18400,
                                17000
                            ],
                            [
                                "Tue",
                                21300,
                                18000
                            ]
                        ]
                    },
                    "xAxis": {
                        "type": "category"
                    },
                    "yAxis": {},
                    "series": [
                        {
                            "type": "bar"
                        },
                        {
                            "type": "line"
                        }
                    ]
                },
                "note": "Revenue remained above target.",
                "note_updated_at": "2026-08-08 11:42:16"
            }
        ]
    }
}

Representative success response. Timestamps, IDs, report data, and notes reflect the organization's stored report.

cURL requestShell
export MFE_API_KEY='paste-your-full-api-key'
export REPORT_ID='c4e53143da3f4f538ad9bd12'

curl -sS -X POST https://api.madfishelements.com/api/v1/visualizations/reports \
  -H "Authorization: Bearer $MFE_API_KEY" \
  -H "Content-Type: application/json" \
  --data-binary @report.json

Set MFE_API_KEY to the full active key generated in Connections & Keys.

Python requestrequests
import os
import requests

report_id = "c4e53143da3f4f538ad9bd12"
url = f"https://api.madfishelements.com/api/v1/visualizations/reports"
headers = {"Authorization": f"Bearer {os.environ['MFE_API_KEY']}"}
payload = {
    "external_id": "llm-weekly-revenue",
    "user_id": 198,
    "title": "Weekly Revenue Brief",
    "description": "A weekly revenue report produced by the analytics pipeline.",
    "status": "published",
    "date_range": "Aug 2-8, 2026",
    "schedule": "Every Monday at 08:00 PT",
    "layout": {
        "columns": 12,
        "gap": 16
    },
    "widgets": [
        {
            "id": "revenue-trend",
            "type": "chart",
            "title": "Revenue vs target",
            "width": 8,
            "height": 360,
            "option": {
                "tooltip": {
                    "trigger": "axis"
                },
                "dataset": {
                    "source": [
                        [
                            "day",
                            "Revenue",
                            "Target"
                        ],
                        [
                            "Mon",
                            18400,
                            17000
                        ],
                        [
                            "Tue",
                            21300,
                            18000
                        ]
                    ]
                },
                "xAxis": {
                    "type": "category"
                },
                "yAxis": {},
                "series": [
                    {
                        "type": "bar"
                    },
                    {
                        "type": "line"
                    }
                ]
            },
            "note": "Revenue remained above target."
        }
    ]
}

response = requests.post(url, headers=headers, json=payload, timeout=30)
response.raise_for_status()
print(response.json())

Install the client with python -m pip install requests.

GET/api/v1/visualizations/reports

List reports

Returns every report summary in the API key organization, including archived reports, ordered by most recently updated. The collection endpoint currently has no pagination or filter parameters.

Available request fieldsGET /api/v1/visualizations/reports
FieldTypeRequirementDescription
(none)NoneNot applicableThis endpoint has no path, query-string, or JSON body fields. Send only the authorization header.
JSON request bodyNo body
{}

This operation has no JSON body. The empty object is shown only to make that absence explicit; do not send it.

JSON response body200 OK
{
    "status": "ok",
    "data": {
        "reports": [
            {
                "id": "c4e53143da3f4f538ad9bd12",
                "external_id": "llm-weekly-revenue",
                "title": "Weekly Revenue Brief",
                "status": "Published",
                "type": "Data visualization",
                "date_range": "Aug 2-8, 2026",
                "schedule": "Every Monday at 08:00 PT",
                "client_id": 4,
                "user_id": 198,
                "user_label": "Example Customer u00b7 reports@example.com",
                "owner_user_id": 583,
                "updated_at": "2026-08-08 11:42:16",
                "updated_display": "Aug 8, 2026",
                "share_enabled": false,
                "widget_types": [
                    "Chart"
                ]
            }
        ]
    }
}

Representative success response. Timestamps, IDs, report data, and notes reflect the organization's stored report.

cURL requestShell
export MFE_API_KEY='paste-your-full-api-key'
export REPORT_ID='c4e53143da3f4f538ad9bd12'

curl -sS -X GET https://api.madfishelements.com/api/v1/visualizations/reports \
  -H "Authorization: Bearer $MFE_API_KEY"

Set MFE_API_KEY to the full active key generated in Connections & Keys.

Python requestrequests
import os
import requests

report_id = "c4e53143da3f4f538ad9bd12"
url = f"https://api.madfishelements.com/api/v1/visualizations/reports"
headers = {"Authorization": f"Bearer {os.environ['MFE_API_KEY']}"}

response = requests.get(url, headers=headers, timeout=30)
response.raise_for_status()
print(response.json())

Install the client with python -m pip install requests.

GET/api/v1/visualizations/reports/{report_id}

Retrieve a report

Returns normalized report metadata, the original source JSON, the current widgets and notes, layout settings, and share-link state.

Available request fieldsGET /api/v1/visualizations/reports/{report_id}
FieldTypeRequirementDescription
report_idStringRequired path fieldThe 24-character lowercase report ID returned by create or list. Reports outside the API key organization return 404.
JSON request bodyNo body
{}

This operation has no JSON body. The empty object is shown only to make that absence explicit; do not send it.

JSON response body200 OK
{
    "status": "ok",
    "data": {
        "id": "c4e53143da3f4f538ad9bd12",
        "external_id": "llm-weekly-revenue",
        "title": "Weekly Revenue Brief",
        "status": "Published",
        "type": "Data visualization",
        "date_range": "Aug 2-8, 2026",
        "schedule": "Every Monday at 08:00 PT",
        "client_id": 4,
        "user_id": 198,
        "user_label": "Example Customer u00b7 reports@example.com",
        "owner_user_id": 583,
        "updated_at": "2026-08-08 11:42:16",
        "updated_display": "Aug 8, 2026",
        "share_enabled": false,
        "widget_types": [
            "Chart"
        ],
        "description": "A weekly revenue report produced by the analytics pipeline.",
        "layout": {
            "columns": 12,
            "gap": 16
        },
        "source": {
            "external_id": "llm-weekly-revenue",
            "user_id": 198,
            "title": "Weekly Revenue Brief",
            "description": "A weekly revenue report produced by the analytics pipeline.",
            "status": "published",
            "date_range": "Aug 2-8, 2026",
            "schedule": "Every Monday at 08:00 PT",
            "layout": {
                "columns": 12,
                "gap": 16
            },
            "widgets": [
                {
                    "id": "revenue-trend",
                    "type": "chart",
                    "title": "Revenue vs target",
                    "width": 8,
                    "height": 360,
                    "option": {
                        "tooltip": {
                            "trigger": "axis"
                        },
                        "dataset": {
                            "source": [
                                [
                                    "day",
                                    "Revenue",
                                    "Target"
                                ],
                                [
                                    "Mon",
                                    18400,
                                    17000
                                ],
                                [
                                    "Tue",
                                    21300,
                                    18000
                                ]
                            ]
                        },
                        "xAxis": {
                            "type": "category"
                        },
                        "yAxis": {},
                        "series": [
                            {
                                "type": "bar"
                            },
                            {
                                "type": "line"
                            }
                        ]
                    },
                    "note": "Revenue remained above target."
                }
            ]
        },
        "share_url": "",
        "widgets": [
            {
                "id": "revenue-trend",
                "type": "chart",
                "title": "Revenue vs target",
                "width": 8,
                "height": 360,
                "option": {
                    "tooltip": {
                        "trigger": "axis"
                    },
                    "dataset": {
                        "source": [
                            [
                                "day",
                                "Revenue",
                                "Target"
                            ],
                            [
                                "Mon",
                                18400,
                                17000
                            ],
                            [
                                "Tue",
                                21300,
                                18000
                            ]
                        ]
                    },
                    "xAxis": {
                        "type": "category"
                    },
                    "yAxis": {},
                    "series": [
                        {
                            "type": "bar"
                        },
                        {
                            "type": "line"
                        }
                    ]
                },
                "note": "Revenue remained above target.",
                "note_updated_at": "2026-08-08 11:42:16"
            }
        ]
    }
}

Representative success response. Timestamps, IDs, report data, and notes reflect the organization's stored report.

cURL requestShell
export MFE_API_KEY='paste-your-full-api-key'
export REPORT_ID='c4e53143da3f4f538ad9bd12'

curl -sS -X GET https://api.madfishelements.com/api/v1/visualizations/reports/$REPORT_ID \
  -H "Authorization: Bearer $MFE_API_KEY"

Set MFE_API_KEY to the full active key generated in Connections & Keys.

Python requestrequests
import os
import requests

report_id = "c4e53143da3f4f538ad9bd12"
url = f"https://api.madfishelements.com/api/v1/visualizations/reports/{report_id}"
headers = {"Authorization": f"Bearer {os.environ['MFE_API_KEY']}"}

response = requests.get(url, headers=headers, timeout=30)
response.raise_for_status()
print(response.json())

Install the client with python -m pip install requests.

PUT/api/v1/visualizations/reports/{report_id}

Replace a report

Sends a complete report representation. PATCH is accepted by the route but follows the same complete-payload validation: title and a non-empty widgets array are still required. Widgets omitted from the body are removed.

Available request fieldsPUT /api/v1/visualizations/reports/{report_id}
FieldTypeRequirementDescription
report_idStringRequired path fieldThe 24-character lowercase report ID returned by create or list. Reports outside the API key organization return 404.
titleStringRequiredNon-empty report title, maximum 255 characters.
widgetsArrayRequiredNon-empty list containing 1-100 widget objects. Widget IDs must be unique within the report.
user_idIntegerOptional; API key userPrimary active user within the report's parent account. When omitted on create, the API key owner is used; updates retain the existing user.
external_idStringOptional; generatedStable producer ID, maximum 128 characters. Reusing it on POST replaces that organization's existing report.
descriptionStringOptional; emptyReport description, maximum 65,535 bytes.
statusStringOptional; draftOne of draft, published, scheduled, shared, or archived.
date_rangeStringOptional; emptyHuman-readable reporting-period label, maximum 128 characters.
scheduleStringOptional; ManualHuman-readable refresh or delivery label, maximum 64 characters.
layoutObjectOptional; 12 columnsJSON layout configuration. The portal uses columns and gap; default is {"columns":12,"gap":16}.
JSON request bodyreport.json
{
    "external_id": "llm-weekly-revenue",
    "user_id": 198,
    "title": "Weekly Revenue and Pipeline Brief",
    "description": "An updated executive view produced by the revenue pipeline.",
    "status": "published",
    "date_range": "Aug 2-8, 2026",
    "schedule": "Every Monday at 08:00 PT",
    "layout": {
        "columns": 12,
        "gap": 16
    },
    "widgets": [
        {
            "id": "revenue-trend",
            "type": "chart",
            "title": "Revenue vs target",
            "width": 8,
            "height": 360,
            "option": {
                "tooltip": {
                    "trigger": "axis"
                },
                "dataset": {
                    "source": [
                        [
                            "day",
                            "Revenue",
                            "Target"
                        ],
                        [
                            "Mon",
                            18400,
                            17000
                        ],
                        [
                            "Tue",
                            21300,
                            18000
                        ]
                    ]
                },
                "xAxis": {
                    "type": "category"
                },
                "yAxis": {},
                "series": [
                    {
                        "type": "bar"
                    },
                    {
                        "type": "line"
                    }
                ]
            },
            "note": "Revenue remained above target."
        },
        {
            "id": "pipeline-coverage",
            "type": "kpi",
            "title": "Pipeline coverage",
            "width": 4,
            "height": 220,
            "value": "3.8x",
            "label": "Next-quarter target",
            "delta": "+0.4x"
        }
    ]
}

Send this object as application/json.

JSON response body200 OK
{
    "status": "ok",
    "message": "Report updated.",
    "data": {
        "id": "c4e53143da3f4f538ad9bd12",
        "external_id": "llm-weekly-revenue",
        "title": "Weekly Revenue and Pipeline Brief",
        "status": "Published",
        "type": "Data visualization",
        "date_range": "Aug 2-8, 2026",
        "schedule": "Every Monday at 08:00 PT",
        "client_id": 4,
        "user_id": 198,
        "user_label": "Example Customer u00b7 reports@example.com",
        "owner_user_id": 583,
        "updated_at": "2026-08-08 11:42:16",
        "updated_display": "Aug 8, 2026",
        "share_enabled": false,
        "widget_types": [
            "Chart",
            "Kpi"
        ],
        "description": "An updated executive view produced by the revenue pipeline.",
        "layout": {
            "columns": 12,
            "gap": 16
        },
        "source": {
            "external_id": "llm-weekly-revenue",
            "user_id": 198,
            "title": "Weekly Revenue and Pipeline Brief",
            "description": "An updated executive view produced by the revenue pipeline.",
            "status": "published",
            "date_range": "Aug 2-8, 2026",
            "schedule": "Every Monday at 08:00 PT",
            "layout": {
                "columns": 12,
                "gap": 16
            },
            "widgets": [
                {
                    "id": "revenue-trend",
                    "type": "chart",
                    "title": "Revenue vs target",
                    "width": 8,
                    "height": 360,
                    "option": {
                        "tooltip": {
                            "trigger": "axis"
                        },
                        "dataset": {
                            "source": [
                                [
                                    "day",
                                    "Revenue",
                                    "Target"
                                ],
                                [
                                    "Mon",
                                    18400,
                                    17000
                                ],
                                [
                                    "Tue",
                                    21300,
                                    18000
                                ]
                            ]
                        },
                        "xAxis": {
                            "type": "category"
                        },
                        "yAxis": {},
                        "series": [
                            {
                                "type": "bar"
                            },
                            {
                                "type": "line"
                            }
                        ]
                    },
                    "note": "Revenue remained above target."
                },
                {
                    "id": "pipeline-coverage",
                    "type": "kpi",
                    "title": "Pipeline coverage",
                    "width": 4,
                    "height": 220,
                    "value": "3.8x",
                    "label": "Next-quarter target",
                    "delta": "+0.4x"
                }
            ]
        },
        "share_url": "",
        "widgets": [
            {
                "id": "revenue-trend",
                "type": "chart",
                "title": "Revenue vs target",
                "width": 8,
                "height": 360,
                "option": {
                    "tooltip": {
                        "trigger": "axis"
                    },
                    "dataset": {
                        "source": [
                            [
                                "day",
                                "Revenue",
                                "Target"
                            ],
                            [
                                "Mon",
                                18400,
                                17000
                            ],
                            [
                                "Tue",
                                21300,
                                18000
                            ]
                        ]
                    },
                    "xAxis": {
                        "type": "category"
                    },
                    "yAxis": {},
                    "series": [
                        {
                            "type": "bar"
                        },
                        {
                            "type": "line"
                        }
                    ]
                },
                "note": "Revenue remained above target.",
                "note_updated_at": "2026-08-08 11:42:16"
            },
            {
                "id": "pipeline-coverage",
                "type": "kpi",
                "title": "Pipeline coverage",
                "width": 4,
                "height": 220,
                "value": "3.8x",
                "label": "Next-quarter target",
                "delta": "+0.4x",
                "note": "",
                "note_updated_at": ""
            }
        ]
    }
}

Representative success response. Timestamps, IDs, report data, and notes reflect the organization's stored report.

cURL requestShell
export MFE_API_KEY='paste-your-full-api-key'
export REPORT_ID='c4e53143da3f4f538ad9bd12'

curl -sS -X PUT https://api.madfishelements.com/api/v1/visualizations/reports/$REPORT_ID \
  -H "Authorization: Bearer $MFE_API_KEY" \
  -H "Content-Type: application/json" \
  --data-binary @report.json

Set MFE_API_KEY to the full active key generated in Connections & Keys.

Python requestrequests
import os
import requests

report_id = "c4e53143da3f4f538ad9bd12"
url = f"https://api.madfishelements.com/api/v1/visualizations/reports/{report_id}"
headers = {"Authorization": f"Bearer {os.environ['MFE_API_KEY']}"}
payload = {
    "external_id": "llm-weekly-revenue",
    "user_id": 198,
    "title": "Weekly Revenue and Pipeline Brief",
    "description": "An updated executive view produced by the revenue pipeline.",
    "status": "published",
    "date_range": "Aug 2-8, 2026",
    "schedule": "Every Monday at 08:00 PT",
    "layout": {
        "columns": 12,
        "gap": 16
    },
    "widgets": [
        {
            "id": "revenue-trend",
            "type": "chart",
            "title": "Revenue vs target",
            "width": 8,
            "height": 360,
            "option": {
                "tooltip": {
                    "trigger": "axis"
                },
                "dataset": {
                    "source": [
                        [
                            "day",
                            "Revenue",
                            "Target"
                        ],
                        [
                            "Mon",
                            18400,
                            17000
                        ],
                        [
                            "Tue",
                            21300,
                            18000
                        ]
                    ]
                },
                "xAxis": {
                    "type": "category"
                },
                "yAxis": {},
                "series": [
                    {
                        "type": "bar"
                    },
                    {
                        "type": "line"
                    }
                ]
            },
            "note": "Revenue remained above target."
        },
        {
            "id": "pipeline-coverage",
            "type": "kpi",
            "title": "Pipeline coverage",
            "width": 4,
            "height": 220,
            "value": "3.8x",
            "label": "Next-quarter target",
            "delta": "+0.4x"
        }
    ]
}

response = requests.put(url, headers=headers, json=payload, timeout=30)
response.raise_for_status()
print(response.json())

Install the client with python -m pip install requests.

POST/api/v1/visualizations/reports/{report_id}/widgets

Append or replace a widget

Appends a new widget and returns 201, or replaces the widget with the same id and returns 200. Both POST and PUT have the same behavior.

Available request fieldsPOST /api/v1/visualizations/reports/{report_id}/widgets
FieldTypeRequirementDescription
report_idStringRequired path fieldThe 24-character lowercase report ID returned by create or list. Reports outside the API key organization return 404.
widgetObjectOptional wrapperMay wrap the widget object. A raw widget object at the top level is also accepted.
idStringRequiredUnique widget identifier. key is accepted as an alias. Starts with a letter; maximum 64 characters.
typeStringOptional; chartOne of chart, table, kpi, or dataset.
titleStringOptionalDisplay title, up to 255 characters.
widthIntegerOptional; 12Width in the 12-column report grid. Allowed range: 1 through 12.
heightIntegerOptional; 320Rendered height in pixels. Allowed range: 160 through 1,400.
noteStringOptionalPersisted commentary for the widget, up to 20,000 bytes.
optionObjectChart onlySafe declarative chart configuration. Must contain at least one supported series.
columnsArrayTable onlyNon-empty list of column strings or {key, label} objects.
rowsArrayTable onlyRow arrays aligned with columns, or row objects keyed by the column key.
valueScalar or nullKPI onlyPrimary KPI value. Required for kpi widgets.
labelStringKPI optionalSupporting KPI label.
deltaScalarKPI optionalComparison or change displayed below the primary value.
dataAny JSONDataset optionalJSON value shown by a dataset widget. dataset is accepted as a fallback alias.
JSON request bodywidget.json
{
    "widget": {
        "id": "regional-detail",
        "type": "table",
        "title": "Regional performance",
        "width": 12,
        "height": 360,
        "columns": [
            {
                "key": "region",
                "label": "Region"
            },
            {
                "key": "revenue",
                "label": "Revenue"
            },
            {
                "key": "growth",
                "label": "Growth"
            }
        ],
        "rows": [
            {
                "region": "West",
                "revenue": "$218,400",
                "growth": "12.4%"
            },
            {
                "region": "Central",
                "revenue": "$176,900",
                "growth": "8.1%"
            }
        ],
        "note": "West remains the strongest growth region."
    }
}

Send this object as application/json.

JSON response body201 Created
{
    "status": "ok",
    "message": "Report updated.",
    "data": {
        "id": "c4e53143da3f4f538ad9bd12",
        "external_id": "llm-weekly-revenue",
        "title": "Weekly Revenue and Pipeline Brief",
        "status": "Published",
        "type": "Data visualization",
        "date_range": "Aug 2-8, 2026",
        "schedule": "Every Monday at 08:00 PT",
        "client_id": 4,
        "user_id": 198,
        "user_label": "Example Customer u00b7 reports@example.com",
        "owner_user_id": 583,
        "updated_at": "2026-08-08 11:42:16",
        "updated_display": "Aug 8, 2026",
        "share_enabled": false,
        "widget_types": [
            "Chart",
            "Kpi",
            "Table"
        ],
        "description": "An updated executive view produced by the revenue pipeline.",
        "layout": {
            "columns": 12,
            "gap": 16
        },
        "source": {
            "external_id": "llm-weekly-revenue",
            "user_id": 198,
            "title": "Weekly Revenue and Pipeline Brief",
            "description": "An updated executive view produced by the revenue pipeline.",
            "status": "published",
            "date_range": "Aug 2-8, 2026",
            "schedule": "Every Monday at 08:00 PT",
            "layout": {
                "columns": 12,
                "gap": 16
            },
            "widgets": [
                {
                    "id": "revenue-trend",
                    "type": "chart",
                    "title": "Revenue vs target",
                    "width": 8,
                    "height": 360,
                    "option": {
                        "tooltip": {
                            "trigger": "axis"
                        },
                        "dataset": {
                            "source": [
                                [
                                    "day",
                                    "Revenue",
                                    "Target"
                                ],
                                [
                                    "Mon",
                                    18400,
                                    17000
                                ],
                                [
                                    "Tue",
                                    21300,
                                    18000
                                ]
                            ]
                        },
                        "xAxis": {
                            "type": "category"
                        },
                        "yAxis": {},
                        "series": [
                            {
                                "type": "bar"
                            },
                            {
                                "type": "line"
                            }
                        ]
                    },
                    "note": "Revenue remained above target."
                },
                {
                    "id": "pipeline-coverage",
                    "type": "kpi",
                    "title": "Pipeline coverage",
                    "width": 4,
                    "height": 220,
                    "value": "3.8x",
                    "label": "Next-quarter target",
                    "delta": "+0.4x"
                },
                {
                    "id": "regional-detail",
                    "type": "table",
                    "title": "Regional performance",
                    "width": 12,
                    "height": 360,
                    "columns": [
                        {
                            "key": "region",
                            "label": "Region"
                        },
                        {
                            "key": "revenue",
                            "label": "Revenue"
                        },
                        {
                            "key": "growth",
                            "label": "Growth"
                        }
                    ],
                    "rows": [
                        {
                            "region": "West",
                            "revenue": "$218,400",
                            "growth": "12.4%"
                        },
                        {
                            "region": "Central",
                            "revenue": "$176,900",
                            "growth": "8.1%"
                        }
                    ],
                    "note": "West remains the strongest growth region."
                }
            ]
        },
        "share_url": "",
        "widgets": [
            {
                "id": "revenue-trend",
                "type": "chart",
                "title": "Revenue vs target",
                "width": 8,
                "height": 360,
                "option": {
                    "tooltip": {
                        "trigger": "axis"
                    },
                    "dataset": {
                        "source": [
                            [
                                "day",
                                "Revenue",
                                "Target"
                            ],
                            [
                                "Mon",
                                18400,
                                17000
                            ],
                            [
                                "Tue",
                                21300,
                                18000
                            ]
                        ]
                    },
                    "xAxis": {
                        "type": "category"
                    },
                    "yAxis": {},
                    "series": [
                        {
                            "type": "bar"
                        },
                        {
                            "type": "line"
                        }
                    ]
                },
                "note": "Revenue remained above target.",
                "note_updated_at": "2026-08-08 11:42:16"
            },
            {
                "id": "pipeline-coverage",
                "type": "kpi",
                "title": "Pipeline coverage",
                "width": 4,
                "height": 220,
                "value": "3.8x",
                "label": "Next-quarter target",
                "delta": "+0.4x",
                "note": "",
                "note_updated_at": ""
            },
            {
                "id": "regional-detail",
                "type": "table",
                "title": "Regional performance",
                "width": 12,
                "height": 360,
                "columns": [
                    {
                        "key": "region",
                        "label": "Region"
                    },
                    {
                        "key": "revenue",
                        "label": "Revenue"
                    },
                    {
                        "key": "growth",
                        "label": "Growth"
                    }
                ],
                "rows": [
                    {
                        "region": "West",
                        "revenue": "$218,400",
                        "growth": "12.4%"
                    },
                    {
                        "region": "Central",
                        "revenue": "$176,900",
                        "growth": "8.1%"
                    }
                ],
                "note": "West remains the strongest growth region.",
                "note_updated_at": "2026-08-08 11:42:16"
            }
        ]
    }
}

Representative success response. Timestamps, IDs, report data, and notes reflect the organization's stored report.

cURL requestShell
export MFE_API_KEY='paste-your-full-api-key'
export REPORT_ID='c4e53143da3f4f538ad9bd12'

curl -sS -X POST https://api.madfishelements.com/api/v1/visualizations/reports/$REPORT_ID/widgets \
  -H "Authorization: Bearer $MFE_API_KEY" \
  -H "Content-Type: application/json" \
  --data-binary @widget.json

Set MFE_API_KEY to the full active key generated in Connections & Keys.

Python requestrequests
import os
import requests

report_id = "c4e53143da3f4f538ad9bd12"
url = f"https://api.madfishelements.com/api/v1/visualizations/reports/{report_id}/widgets"
headers = {"Authorization": f"Bearer {os.environ['MFE_API_KEY']}"}
payload = {
    "widget": {
        "id": "regional-detail",
        "type": "table",
        "title": "Regional performance",
        "width": 12,
        "height": 360,
        "columns": [
            {
                "key": "region",
                "label": "Region"
            },
            {
                "key": "revenue",
                "label": "Revenue"
            },
            {
                "key": "growth",
                "label": "Growth"
            }
        ],
        "rows": [
            {
                "region": "West",
                "revenue": "$218,400",
                "growth": "12.4%"
            },
            {
                "region": "Central",
                "revenue": "$176,900",
                "growth": "8.1%"
            }
        ],
        "note": "West remains the strongest growth region."
    }
}

response = requests.post(url, headers=headers, json=payload, timeout=30)
response.raise_for_status()
print(response.json())

Install the client with python -m pip install requests.

DELETE/api/v1/visualizations/reports/{report_id}

Archive a report

Sets the report status to archived and retains its source, widgets, notes, and report ID. Archived reports remain visible in the list response.

Available request fieldsDELETE /api/v1/visualizations/reports/{report_id}
FieldTypeRequirementDescription
report_idStringRequired path fieldThe 24-character lowercase report ID returned by create or list. Reports outside the API key organization return 404.
JSON request bodyNo body
{}

This operation has no JSON body. The empty object is shown only to make that absence explicit; do not send it.

JSON response body200 OK
{
    "status": "ok",
    "message": "Report updated.",
    "data": {
        "id": "c4e53143da3f4f538ad9bd12",
        "external_id": "llm-weekly-revenue",
        "title": "Weekly Revenue and Pipeline Brief",
        "status": "Archived",
        "type": "Data visualization",
        "date_range": "Aug 2-8, 2026",
        "schedule": "Every Monday at 08:00 PT",
        "client_id": 4,
        "user_id": 198,
        "user_label": "Example Customer u00b7 reports@example.com",
        "owner_user_id": 583,
        "updated_at": "2026-08-08 11:42:16",
        "updated_display": "Aug 8, 2026",
        "share_enabled": false,
        "widget_types": [
            "Chart",
            "Kpi",
            "Table"
        ],
        "description": "An updated executive view produced by the revenue pipeline.",
        "layout": {
            "columns": 12,
            "gap": 16
        },
        "source": {
            "external_id": "llm-weekly-revenue",
            "user_id": 198,
            "title": "Weekly Revenue and Pipeline Brief",
            "description": "An updated executive view produced by the revenue pipeline.",
            "status": "archived",
            "date_range": "Aug 2-8, 2026",
            "schedule": "Every Monday at 08:00 PT",
            "layout": {
                "columns": 12,
                "gap": 16
            },
            "widgets": [
                {
                    "id": "revenue-trend",
                    "type": "chart",
                    "title": "Revenue vs target",
                    "width": 8,
                    "height": 360,
                    "option": {
                        "tooltip": {
                            "trigger": "axis"
                        },
                        "dataset": {
                            "source": [
                                [
                                    "day",
                                    "Revenue",
                                    "Target"
                                ],
                                [
                                    "Mon",
                                    18400,
                                    17000
                                ],
                                [
                                    "Tue",
                                    21300,
                                    18000
                                ]
                            ]
                        },
                        "xAxis": {
                            "type": "category"
                        },
                        "yAxis": {},
                        "series": [
                            {
                                "type": "bar"
                            },
                            {
                                "type": "line"
                            }
                        ]
                    },
                    "note": "Revenue remained above target."
                },
                {
                    "id": "pipeline-coverage",
                    "type": "kpi",
                    "title": "Pipeline coverage",
                    "width": 4,
                    "height": 220,
                    "value": "3.8x",
                    "label": "Next-quarter target",
                    "delta": "+0.4x"
                },
                {
                    "id": "regional-detail",
                    "type": "table",
                    "title": "Regional performance",
                    "width": 12,
                    "height": 360,
                    "columns": [
                        {
                            "key": "region",
                            "label": "Region"
                        },
                        {
                            "key": "revenue",
                            "label": "Revenue"
                        },
                        {
                            "key": "growth",
                            "label": "Growth"
                        }
                    ],
                    "rows": [
                        {
                            "region": "West",
                            "revenue": "$218,400",
                            "growth": "12.4%"
                        },
                        {
                            "region": "Central",
                            "revenue": "$176,900",
                            "growth": "8.1%"
                        }
                    ],
                    "note": "West remains the strongest growth region."
                }
            ]
        },
        "share_url": "",
        "widgets": [
            {
                "id": "revenue-trend",
                "type": "chart",
                "title": "Revenue vs target",
                "width": 8,
                "height": 360,
                "option": {
                    "tooltip": {
                        "trigger": "axis"
                    },
                    "dataset": {
                        "source": [
                            [
                                "day",
                                "Revenue",
                                "Target"
                            ],
                            [
                                "Mon",
                                18400,
                                17000
                            ],
                            [
                                "Tue",
                                21300,
                                18000
                            ]
                        ]
                    },
                    "xAxis": {
                        "type": "category"
                    },
                    "yAxis": {},
                    "series": [
                        {
                            "type": "bar"
                        },
                        {
                            "type": "line"
                        }
                    ]
                },
                "note": "Revenue remained above target.",
                "note_updated_at": "2026-08-08 11:42:16"
            },
            {
                "id": "pipeline-coverage",
                "type": "kpi",
                "title": "Pipeline coverage",
                "width": 4,
                "height": 220,
                "value": "3.8x",
                "label": "Next-quarter target",
                "delta": "+0.4x",
                "note": "",
                "note_updated_at": ""
            },
            {
                "id": "regional-detail",
                "type": "table",
                "title": "Regional performance",
                "width": 12,
                "height": 360,
                "columns": [
                    {
                        "key": "region",
                        "label": "Region"
                    },
                    {
                        "key": "revenue",
                        "label": "Revenue"
                    },
                    {
                        "key": "growth",
                        "label": "Growth"
                    }
                ],
                "rows": [
                    {
                        "region": "West",
                        "revenue": "$218,400",
                        "growth": "12.4%"
                    },
                    {
                        "region": "Central",
                        "revenue": "$176,900",
                        "growth": "8.1%"
                    }
                ],
                "note": "West remains the strongest growth region.",
                "note_updated_at": "2026-08-08 11:42:16"
            }
        ]
    }
}

Representative success response. Timestamps, IDs, report data, and notes reflect the organization's stored report.

cURL requestShell
export MFE_API_KEY='paste-your-full-api-key'
export REPORT_ID='c4e53143da3f4f538ad9bd12'

curl -sS -X DELETE https://api.madfishelements.com/api/v1/visualizations/reports/$REPORT_ID \
  -H "Authorization: Bearer $MFE_API_KEY"

Set MFE_API_KEY to the full active key generated in Connections & Keys.

Python requestrequests
import os
import requests

report_id = "c4e53143da3f4f538ad9bd12"
url = f"https://api.madfishelements.com/api/v1/visualizations/reports/{report_id}"
headers = {"Authorization": f"Bearer {os.environ['MFE_API_KEY']}"}

response = requests.delete(url, headers=headers, timeout=30)
response.raise_for_status()
print(response.json())

Install the client with python -m pip install requests.

Build against the complete schema

Use the types and fields page for validation rules, allowed chart series, normalized response fields, and examples of every widget type.

View all fields