Workspace API guide
How to get a workspace API token and call the authenticated workspace API safely from your server. For exact fields and headers, see the API reference.
See also: Public API guide.
Credential and permission #
| Operation | Credential | Required permission |
|---|---|---|
getPublicCreator (/api/v1/creators/{slug}) | None (anonymous) | None |
listWorkspaceBroadcasts (/api/v1/workspace/broadcasts) | Workspace API token (Authorization: Bearer) | broadcasts:read |
A workspace API token belongs to one workspace and can only read that workspace. Tokens never grant write access, and broadcasts:read is the only permission today.
Getting a token #
Only the workspace Owner can create, view, or revoke tokens. Sign in to CreatorRoots and open Settings → Developer access, then create a token, choose its expiry, and copy it. Administrators, Moderators, and other delegated users cannot, even when they are working in your workspace.
- The token (
crapi_...) is shown once, when you create it. CreatorRoots stores only a one-way hash, so it cannot be shown again. Copy it into your server's secret store immediately; if you lose it, revoke it and create another. - Every token has an expiry: 90 days by default, from 1 to 365 days. Expired tokens stop working and cannot be extended. Create a replacement before the old one expires.
- A workspace can have up to 5 active tokens. Expired and revoked tokens do not count.
- The token list shows each token's name, last four characters, permissions, status (
active,expired,revoked), expiry, and last use. It never shows the secret. - Revoking is immediate and permanent.
Tokens stop working while an account is suspended and when its deletion is accepted. A suspension that is lifted restores tokens that are still unexpired and unrevoked.
Calling the API #
Send the token in the Authorization header, from a server. Keep it in an environment variable or secret manager, never in source control, browser code, or a mobile app.
export CREATORROOTS_API_TOKEN="<your workspace API token>"
curl -s https://api.creatorroots.com/api/v1/workspace/broadcasts?per_page=25 \
-H "Authorization: Bearer $CREATORROOTS_API_TOKEN" \
-H "Accept: application/json"{
"data": [
{
"id": "brd_q3X9bT7mL2vKp0aZc8RnWd",
"started_at": "2026-11-14T19:02:11.000000Z",
"ended_at": null,
"status": "active",
"duration_seconds": 5400,
"platforms": ["twitch"]
}
],
"links": { "next": "https://api.creatorroots.com/api/v1/workspace/broadcasts?per_page=25&cursor=eyJ0IjoxNzYzMDAwMDAwLCJpIjo0Mn0" },
"meta": { "schema": "v1", "per_page": 25 }
}The token alone decides the workspace. Cookies, X-Creator-Context, and workspace or creator ids in the query string are ignored, and a token placed in the query string is not accepted.
Server-to-server only #
The workspace API sends no Access-Control-* headers and does not answer CORS preflight, so a web page cannot call it, including pages on app.creatorroots.com. This is deliberate: a token in browser code is exposed to everyone who loads the page. The anonymous public creator API keeps its separate, browser-friendly Access-Control-Allow-Origin: * behavior.
Broadcasts #
Each item has:
id: an opaque identifier. It stays the same between requests under normal operation, but it is derived with a CreatorRoots signing key (APP_KEY), so it can change if that key is rotated. Do not parse it, and do not use it as a permanent key in your own data; if you store it, be prepared to re-sync bystarted_atafter a rotation.started_at/ended_at: UTC ISO 8601.ended_atisnullwhile the broadcast is active.status:activeorended.duration_seconds: start to end, or start to the time of the request while active.platforms: distinct platform identifiers such astwitch, earliest first. Treat unknown values as opaque strings.
Viewer metrics, chat, supporters, revenue, and provider account or session identifiers are not part of this response.
Pagination #
Results are newest first (started_at, then an internal tie-breaker, descending), so broadcasts that started in the same second are never skipped or repeated. Use links.next exactly as returned until it is null. Cursors are opaque; do not construct or edit them. per_page is 1 to 100 (default 25). A broadcast that starts while you are paging appears only on a fresh request from the first page.
Errors #
All errors use { "error": { "code": "...", "message": "..." } }. Branch on code, not message.
| Status | code | Meaning |
|---|---|---|
| 401 | unauthenticated | No token, or the token is malformed, unknown, expired, revoked, or its workspace is unavailable. The cause is never revealed. Includes WWW-Authenticate: Bearer. |
| 403 | insufficient_scope | The token is valid but lacks broadcasts:read. error.required_scope names the permission. |
| 422 | invalid_parameter | per_page is out of range or not an integer. error.parameter names it. |
| 422 | invalid_cursor | cursor is not one issued by this API. |
| 429 | rate_limited | Too many requests. Wait Retry-After seconds. |
On 401, stop and check or replace the token. Do not retry in a loop; repeated failures from one IP are rate limited.
Rate limits and caching #
- Valid tokens: 60 requests per minute per token.
X-RateLimit-LimitandX-RateLimit-Remainingare sent on successful responses. - Bad or missing credentials: 30 failures per minute per client IP. This does not reduce the budget of valid tokens.
- Over a limit, you receive
429withRetry-After(seconds). - Responses carry
Cache-Control: no-store, privateandVary: Authorization. Do not cache them in a shared cache; cache in your own application for a short time instead of calling per page view.
Compatibility policy #
This is API v1. Within v1, new fields, new platforms values, and new permissions can be added. Ignore fields you do not recognize. Existing fields are not removed, renamed, or retyped, and error code values are stable. Breaking changes would use a new version path.