Skip to main content

Authentication

Every request carries an API key in the Authorization header:

GET /api/v1/sims HTTP/1.1
Host: app.zentarinetworks.com
Authorization: Bearer axis_live_3k9QmZr…

API keys​

Keys are made and revoked in the Axis portal by an admin, under Settings > Tenant > Developer API. They can't be created through the API: a key that could make keys could never be fully taken back.

FormatStarts axis_live_, followed by random characters
ShownOnce, when it's made. Axis only keeps a fingerprint of it, so it can't show it again
How manyUp to 20 per account. Give each system its own key, named after it
RevokingIn the portal. Requests with that key get 401 straight away

Read-only or full access​

Each key has one of two access levels:

AccessCan doUse it for
read_onlyGET requests onlyDashboards, reporting, monitoring
fullEverythingSystems that provision, suspend, order or top up

A read-only key that tries to change something gets 403 with the code insufficient_access. GET /account tells you which key you're using and its access, so it's a good way to check a key before you rely on it.

Keeping keys safe​

  • Keep keys on your servers, never in a browser, a mobile app, or source control.
  • Use read-only keys wherever you only need to read.
  • Make one key per system, so you can revoke one without touching the others.
  • If a key might have leaked, revoke it in the portal and make a new one. There's no need to contact us first.

When it goes wrong​

StatuscodeMeaning
401unauthorizedNo key was sent, or the header isn't Authorization: Bearer …
401invalid_api_keyThe key doesn't exist or was revoked
403insufficient_accessA read-only key tried to make a change
403account_suspendedYour Axis account is suspended (usually an unpaid invoice); every request is refused until it's sorted

:::note Account suspension While an account is suspended, every API request gets 403 account_suspended, including GETs. The portal tells you why, and support@zentarinetworks.com can help. :::