Skip to main content

Reporting API

Read your organization's usage, plan cost and invoices from your own tools: a spreadsheet, Power BI, a nightly script, or an AI assistant. It is the same data the dashboard shows.

Create a token​

An organization admin creates a reporting token in the dashboard under Organization → API tokens. The page also shows your organization id, which every request needs.

A reporting token is read-only and belongs to one organization. It can read usage, plan cost and invoices, and nothing else: it cannot create keys, invite people or make new tokens. The token is shown once; if you lose it, revoke it and create a new one.

Make a request​

Send the token as a bearer token, and send a User-Agent that names your tool:

curl -s "https://platform.zeldoc.ai/api/orgs/$ORG_ID/key-usage?month=2026-08" \
-H "Authorization: Bearer $ZELDOC_TOKEN" \
-H "User-Agent: my-company-usage-sync/1.0"

The platform is behind Cloudflare, which rejects the default user agent of some HTTP libraries (Python's urllib, for one) with error 1010. Any descriptive value works.

Reference​

Every endpoint, parameter and response field is described in the reference, generated from the platform's own code so it always matches what the API does:

Keep the token out of the chat

Give an assistant the documentation link, not your token. Put the token in an environment variable such as ZELDOC_TOKEN and let the script read it from there.

What your organization sees​

What an organization sees of its money is agreed per customer. When usage, the subscription or invoices are not shared with your organization, those endpoints answer 403. Contact Zeldoc if you need them.