delete_chart
Permanently remove a Datawrapper chart by its ID to manage your visualizations and maintain clean workspaces.
Instructions
⚠️ DATAWRAPPER MCP TOOL ⚠️ This is part of the Datawrapper MCP server integration.
Delete a Datawrapper chart permanently.
Args: chart_id: ID of the chart to delete
Returns: Confirmation message
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| chart_id | Yes |
Implementation Reference
- handlers/delete.py:11-25 (handler)The actual handler function that executes the deletion of a Datawrapper chart.
async def delete_chart(arguments: DeleteChartArgs) -> list[TextContent]: """Delete a chart permanently.""" chart_id = arguments["chart_id"] # Get chart and delete using Pydantic instance method chart = get_chart(chart_id) chart.delete() result = { "chart_id": chart_id, "message": "Chart deleted successfully!", } return [TextContent(type="text", text=json.dumps(result, indent=2))] - dw_types.py:40-44 (schema)The TypedDict definition defining the input arguments (chart_id) for the delete_chart tool.
class DeleteChartArgs(TypedDict): """Arguments for delete_chart handler.""" chart_id: str - server.py:21-21 (registration)Registration of the delete_chart_handler in the main server file.
delete_chart as delete_chart_handler,