Creating a token
From the dashboard: Settings → API Tokens → New token. Provide:- Name — a human-readable label (e.g., “ci-pipeline”)
- Scopes — which resources this token can touch
- Expiration — optional; tokens can live forever or expire on a date
ca_— the product prefixprod_ordev_— the instance environment- The remaining 32 hex characters — the token body
Scopes
Every token has a list of scopes. A request is allowed only if the token holds at least one scope matching the endpoint.| Scope | Grants |
|---|---|
read | Any GET on any resource |
write | Any POST, PATCH, DELETE on any resource |
admin | Rotating secrets, creating tokens, managing webhooks |
company:<id> | Restricts the token to one company |
company:<id>:read | Read-only access to one company |
company:<id>:write | Read and write access to one company |
read, write) are convenient. In
production, prefer per-company scopes so a leaked token from
one company cannot read another.
Examples:
- CI pipeline that creates tasks in one company:
company:ampha-group:write - Metrics exporter that reads everything:
read - Admin script for token rotation:
admin
Checking a token
The simplest health check:Rotating a token
Rotating a token creates a new token with the same name and scopes, returns the new value, and marks the old one for deletion. The old one is still valid for a grace period (default 24 hours) so you can roll your deployments without downtime.Revoking a token
Revocation is immediate. No grace period.- A token has leaked
- An employee with a personal token has left
- A CI job has been taken out of service and will not roll
Listing tokens
Token best practices
- One token per caller. Do not share a token between two pipelines. If one leaks, you have to rotate both.
- Scope tightly. Prefer
company:<id>:writeover a globalwrite. - Short-lived where possible. For CI tokens, expire after 90 days and rotate as part of the pipeline.
- Store in a secret manager. Never commit a token to a repo, even a private one.
- Audit the list quarterly. Delete tokens that have not been used in the last 30 days.