Skip to main content
The API uses bearer tokens. Create them in Ardent dashboard > Settings > API keys (or via the API keys endpoints) and store them in a secret manager. Keys start with sk-ard_live_ (or sk-ard_test_ in test environments) and go in an Authorization: Bearer header on every request.

Token handling

  • Store tokens in your CI secret manager or platform vault.
  • Do not commit tokens to source control.
  • Rotate tokens when someone leaves the team or a token is exposed.
  • Prefer the least-privileged role that can perform the job.

API key roles

List the roles available in your organization with GET /v1/orgs/{org_id}/roles.

CLI and API tokens

The CLI can also use API tokens through ARDENT_TOKEN:
For local interactive work, ardent login is friendlier. For CI and scripts, ARDENT_TOKEN is more explicit.

Common auth errors

Example: list projects