ChartQuery

Diagram View

View a previously saved diagram as an HTML page. Public — no API key required. Iframe-embeddable with inline SVG rendering.

GET
/v1/diagram/view/{id}

Path Parameters

id*string

The diagram ID returned in the X-Diagram-View-URL header when saving a diagram. Format: cq-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx.

Query Parameters

share?boolean

Set share=true to persist the config and receive JSON instead of an image: { id, render_url, view_url, embed_url, expires_in }. Free plan: 3-day expiry with watermark. Paid plan: 6-month expiry, no branding.

Default"false"
Value in"false" | "true"

Response Body

application/json

application/json

application/json

curl -X GET "https://api.chartquery.com/v1/diagram/view/string"

"<!DOCTYPE html><html><!-- rendered diagram image embedded in a responsive page --></html>"

{
  "error": "Bad Request"
}
{
  "error": "Internal Error"
}