access_token, sent as a bearer token. This guide covers how to obtain one, keep it valid, store it safely, and what to do when authentication fails.
Kardinal currently provisions access by inviting a user (typically your company email) to set a password on an environment such as
https://<env>.kardinal.ai — there is no separate, long-lived “API key” to generate from a dashboard. Your username/password pair is what’s exchanged for short-lived tokens below. If your integration needs a different credential model (e.g. a dedicated service account), raise it with your Account Executive.Obtain an access token
Response
access_token on every request:
Token lifetime and refresh
Anaccess_token is valid for one hour. This short lifetime limits the damage of a leaked token, but it means your integration must refresh proactively rather than waiting for a request to fail:
- Call the
loginendpoint again, or - Use the
refresh_tokenyou received at login against therefreshTokenendpoint to get a newaccess_tokenwithout re-sending the password.
Storing credentials
Treat the username/password and any liveaccess_token / refresh_token like any other production secret:
- Store them in environment variables or a secrets manager (Vault, AWS/GCP/Azure secret managers, etc.) — never hard-code them in source control.
- Keep sandbox and production credentials in separate secrets, scoped to separate deployment environments.
- Log requests without the
Authorizationheader value; if you need to debug a 401, log the response body, not the token. - If a password or refresh token is suspected to be compromised, contact your Kardinal support channel (
api@kardinal.aior your Account Executive) to have access reset — there is no documented self-service revocation endpoint at this time.
Common authentication issues
Exact HTTP status codes and error bodies for these cases will be documented in Error codes once confirmed against the live API.