Build chart integrations with the Charta API. Generate charts programmatically, connect via MCP, or use our TypeScript SDK.
Generate charts via HTTP. Send a JSON payload describing your chart and receive a rendered image or native Google Slides insert.
curl -X POST https://api.getcharta.ai/v1/charts \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"type": "waterfall",
"title": "Revenue Bridge Q1 → Q2",
"data": [
{ "label": "Q1 Revenue", "value": 1200 },
{ "label": "New Sales", "value": 340 },
{ "label": "Churn", "value": -120 },
{ "label": "Expansion", "value": 80 },
{ "label": "Q2 Revenue", "value": 1500, "total": true }
]
}'Connect Charta to Claude, Cursor, or any MCP-compatible AI client. Let your AI assistant create and insert charts directly.
{
"mcpServers": {
"charta": {
"command": "npx",
"args": ["-y", "@charta/mcp-server"],
"env": {
"CHARTA_API_KEY": "your-api-key"
}
}
}
}create_chart — Generate a chart from structured datalist_chart_types — List all supported chart typesinsert_into_slide — Insert a generated chart into a Google Slideupdate_chart_data — Update data in an existing chartType-safe chart generation with full autocomplete support.
npm install @charta/sdkimport { Charta } from "@charta/sdk";
const charta = new Charta({ apiKey: process.env.CHARTA_API_KEY });
const chart = await charta.charts.create({
type: "mekko",
title: "Market Share by Segment",
data: {
categories: ["Enterprise", "Mid-Market", "SMB"],
series: [
{ name: "Us", values: [45, 30, 15] },
{ name: "Competitor A", values: [30, 35, 40] },
{ name: "Others", values: [25, 35, 45] },
],
},
});
// Insert into a Google Slide
await charta.slides.insert({
presentationId: "your-presentation-id",
slideIndex: 0,
chartId: chart.id,
});All API requests require a Bearer token. Generate your API key in the Charta dashboard under Settings → API Keys. Keep your key secret — never expose it in client-side code.
| Plan | Requests / min | Daily credits |
|---|---|---|
| Free | 10 | 5 |
| Plus | 30 | 20 |
| Business | 120 | Unlimited |