Chart AI
Describe a chart in plain English via GET and get a rendered image back. Powered by AI.
Credit cost: 10 credits per call
Autorização
ApiKeyAuth Your API key. Include it in the x-api-key header for every request.
In: header
Parâmetros de consulta
Describe your chart in plain English (max 1000 chars). Be specific: mention chart type, data topic, colors, style.
Raw data for the chart. URL-encoded string, CSV, or JSON. AI will parse and structure it.
Examples:
- String:
Jan: 12400, Feb: 18900, Mar: 15200 - JSON array:
[{"month":"Jan","a":120,"b":85},{"month":"Feb","a":145,"b":102}] - JSON object:
{"Organic":38,"Paid":24,"Direct":18}
Limit: 10 000 characters / 500 items. Need more? Open a support ticket.
Override the chart title generated by AI.
Override the chart subtitle.
Legend position or visibility. Use "false" to hide.
"top"Value in
- "top"
- "bottom"
- "left"
- "right"
- "chartArea"
- "false"
Output format. Default: "png".
"png"Value in
- "png"
- "svg"
Image width in pixels (50–4000). Default: 1200.
Image height in pixels (50–4000). Default: 600.
Background color as a hex value. Default: #ffffff.
Device pixel ratio for the rendered image. Default: 1.
Corpo da resposta
application/json
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/v1/chart/ai?prompt=string""(binary image/png: use directly in <img src=\"...\"> or download)"{ "error": "Bad Request"}{ "error": "Invalid API Key"}{ "error": "Payment required"}{ "error": "Rate limit exceeded for the API key: quota monthly"}{ "error": "Internal Error"}