Skip to main content
Every request carries an API key in the x-api-key header. The key identifies your account: every order, bet and figure the API returns belongs to it. The one exception is GET /v1/health, which needs no key. A key sent to it is ignored.

Getting a key

  1. Access. Your agent enables API access on your account. Until then, you cannot create a key.
  2. Key. In the dashboard, open Preferences → API and create a key.
  3. Storage. The key is shown once, in full. Apexium stores only a hash of it and cannot show it again: keep it in a secret manager. The dashboard then shows only its prefix and its last four characters.
Keys look like apx_live_…. A test environment, with its own base URL and keys, is available on request while you integrate. A key only works in the environment that issued it.

Live keys

You can have two live keys at a time. That is enough to rotate without downtime. To create a third, revoke one first.

Rotating a key

Rotate a key from the same place. Rotation issues a new key and sets an end date on the old one. You choose when the old key stops working: Deploy the new key while both work, then let the old one expire. Rotation needs a free slot: with two live keys, revoke one before rotating the other.

Revoking a key

Revoking stops a key immediately. Revoke a key as soon as you suspect it leaked. If your agent withdraws API access from the account, every key of the account stops at once.

Failed authentication

A request without a key, or with a key that is unknown, revoked or expired, gets 401 INVALID_API_KEY. A valid key gets 403 API_ACCESS_DENIED when the account no longer has API access or is suspended. Repeated failures from the same address are throttled: after 20 failed requests in one minute, every request from that address gets 429 RATE_LIMITED until the minute ends, whatever key it carries. See Limits.

Request identifiers

Every response carries an x-request-id header. Quote it when you contact support about a request.