Skip to main content
Askr uses API keys to authenticate requests. Pass your key as a Bearer token in the Authorization header on every call.

Getting a key

Create and manage keys from your dashboard. Each key draws from the same account balance. You can:
  • Create multiple keys (e.g. one per app or environment).
  • Set a spending limit and reset period per key.
  • Set an expiry date.
  • Revoke a key at any time.
Treat your API key like a password. Never commit it to source control or expose it in front-end code that users can view. For browser apps, route requests through your own backend, or use a per-user key funded by that user.

Keys vs credit ID

Askr accounts have two identifiers:
string
A secret token used to authenticate API calls (Authorization: Bearer ...).
string
A public identifier for your balance, used for reading balance and for top-ups. It is not secret, but it cannot be used to make inference calls.

Test your key

A 200 response with a list of models means your key works.