Skip to main content
Glama
hqu

Datawrapper MCP

by hqu

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
NameRequiredDescriptionDefault
chart_idYes

Implementation Reference

  • 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))]
  • 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,

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/hqu/datawrapper-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server