Skip to main content

Authentication

NexaLayer supports API key authentication. Agents, scripts, and automation jobs should send X-API-Key on each request.
GET /account/info identifies the credential only through api_key_prefix (for example, nx_abcd…wxyz); it never returns the plaintext API key.

Request an API key by email

The response does not include the API key. NexaLayer sends it to the mailbox:
The first request for a new email automatically receives a small one-time trial credit. Later requests resend the existing API key and never grant credit twice.

backend_ready

backend_ready is the real provisioning gate:
  • true: the account is synced and can list products, read balance, and create sessions
  • false: do not create sessions; surface or retry the backend sync problem

Idempotency

For write operations such as session creation, rotation, renewal, and recharge, send an Idempotency-Key:
This lets agents retry safely without duplicating paid operations.