Data Visualization
Generate customizable donut charts (ring charts) from data with various styling options, perfect for showing proportions with a central space
Call this tool from your code in three languages.
curl -X POST 'https://api.elysiatools.com/en/api/tools/donut-chart-generator' \
-H 'Content-Type: application/json' \
-d '{"chartData":"JSON format:\n[{"label": "Product A", "value": 35},\n{"label": "Product B", "value": 25},\n{"label": "Product C", "value": 20},\n{"label": "Product D", "value": 20}]\n\nor text format:\nProduct A:35\nProduct B:25\nProduct C:20\nProduct D:20","chartTitle":"Enter chart title...","colorScheme":"default","centerText":"Total","chartSize":"400","innerRadius":0,"outerRadius":0,"startAngle":"0","backgroundColor":"#ffffff","showPercentage":true,"showLegend":true,"showLabels":true,"showTotalInCenter":false,"explodeSlices":false}'Send a POST request with your inputs as JSON. File parameters require a separate upload first.
POST https://api.elysiatools.com/en/api/tools/donut-chart-generator| Name | Type | Required | Description |
|---|---|---|---|
| chartData | textarea | Yes | Data for the donut chart. Supports JSON array or simple label:value text format |
| chartTitle | text | No | Title that will be displayed above the chart |
| colorScheme | select | No | — |
| centerText | text | No | Text to display in the center of the donut (when showing total) |
| chartSize | number | No | Size of the square chart in pixels |
| innerRadius | number | No | Inner radius of the donut in pixels (leave empty for auto) |
| outerRadius | number | No | Outer radius of the donut in pixels (leave empty for auto) |
| startAngle | number | No | Starting angle in degrees (0 = top, 90 = right) |
| backgroundColor | color | No | Background color for the chart container |
| showPercentage | checkbox | No | Display percentages on the chart slices |
| showLegend | checkbox | No | Display a legend below the chart |
| showLabels | checkbox | No | Display labels or percentages directly on the donut slices |
| showTotalInCenter | checkbox | No | Display the total value in the center of the donut |
| explodeSlices | checkbox | No | Separate slices from each other for emphasis |
HTML result
{
"result": "<div>Processed HTML content</div>",
"error": "Error message (optional)",
"message": "Notification message (optional)",
"metadata": {
"key": "value"
}
}Add this tool to your Model Context Protocol server so AI agents can list and call it.
Add this block to your MCP client configuration:
{
"mcpServers": {
"elysiatools-donut-chart-generator": {
"name": "donut-chart-generator",
"description": "Generate customizable donut charts (ring charts) from data with various styling options, perfect for showing proportions with a central space",
"baseUrl": "https://api.elysiatools.com/mcp/sse?toolId=donut-chart-generator",
"command": "",
"args": [],
"env": {},
"isActive": true,
"type": "sse"
}
}
}After connecting to the SSE endpoint, list the exposed tools:
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/list"
}Invoke the tool by its id, passing arguments built from its parameters:
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "donut-chart-generator",
"arguments": {
"chartData": "JSON format:\n[{"label": "Product A", "value": 35},\n{"label": "Product B", "value": 25},\n{"label": "Product C", "value": 20},\n{"label": "Product D", "value": 20}]\n\nor text format:\nProduct A:35\nProduct B:25\nProduct C:20\nProduct D:20",
"chartTitle": "Enter chart title...",
"colorScheme": "default",
"centerText": "Total",
"chartSize": "400",
"innerRadius": 0,
"outerRadius": 0,
"startAngle": "0",
"backgroundColor": "#ffffff",
"showPercentage": true,
"showLegend": true,
"showLabels": true,
"showTotalInCenter": false,
"explodeSlices": false
}
}
}Questions or issues? Contact [email protected]