Skip to main content
Aura separates three concerns: Private account and private-webhook operations can require both a developer key and the matching wallet session. Restricted order requests instead require the developer key plus the user’s aura_trade_… authorization and do not require an unrelated session bearer. Supplying more scopes to a developer key never substitutes for user consent.

Developer keys

Send a developer key only in this header:
Never append it to a URL. URLs commonly appear in proxy, CDN, browser-history and analytics logs. Available scopes are:
  • public:read and market:read
  • realtime:public
  • account:read
  • transactions:read
  • trade:place and trade:cancel
  • webhooks:manage
Key creation is a wallet-session operation:
The secret is displayed once. Aura stores only its digest. Put the returned value directly in a server-side secret manager. Rotate it rather than copying it between developers, and revoke it when the integration is retired. key.builderCode is the immutable public attribution identity bound to the key owner. It is not secret and grants no authority. For a trading integration, give the user this exact code when they create restricted access in Aura’s first-party console and use a developer key with the required trade:* scopes; the order facade verifies that the authorization binding matches the presented key. Key rotation preserves the code.
Do not embed a privileged developer key in browser JavaScript. Anyone can extract it and consume its quota. Browser code should normally use public access plus the user’s HttpOnly session.

Establish a wallet session

1

Request a one-time challenge

The challenge expires after five minutes and is single-use. Issuing it for a known address is preferred; an address-less challenge must be returned verbatim in the session request.
2

Sign the exact challenge text

Use the wallet’s signMessage operation with the Alephium message hasher. Do not ask for, export, or handle the wallet seed. Aura has no raw seed export flow.
3

Exchange the signature

The browser flow receives an HttpOnly aura_session cookie and a CSRF token in the response. Echo the CSRF token in x-csrf-token on session-owned mutations.
For non-JavaScript implementations, the signed digest is:
The signature is a 64-byte raw r || s secp256k1 signature encoded as lowercase hex. It is not DER and has no recovery byte. Browsers should keep the session in the HttpOnly cookie:
Backends may request issueToken: true when exchanging the challenge and send the returned token as:
Bearer requests do not need CSRF because browsers do not attach an Authorization header automatically. Store the token like any other secret; never put it in a query string, application log or browser localStorage.

Compose builder and user credentials

The request carries both headers. Aura independently checks the key scope and that the path address belongs to the session.

Restricted trading authority

API trading uses a separate, user-created authorization held by Aura’s enclave. It is narrowly limited by account, environment, market/outcome permissions, BUY/SELL caps, expiry and builder attribution. The API signs and submits an authorized intent internally; intent signatures and cancel signatures are not returned to the builder. Users can inspect, rotate and revoke that authorization. Revoking a developer key stops the builder identity; revoking the user authorization stops its trading power. Treat these as independent controls. Creation, rotation and revocation deliberately remain in Aura’s signer iframe and first-party authorization console, where each high-authority action is bound to explicit user consent. The aura_trade_… secret is shown once and delivered to the builder the user selected. The builder must place it directly in a server-side secret store and send it only in x-aura-trading-authorization alongside its developer key. The builder API and @aura/builder-sdk cannot mint or broaden an authorization. Do not call wallet-svc or enclave internal routes. The first-party console keeps the same idempotency key when a create or rotation has an ambiguous transport failure. The authorization service never replays a show-once secret: if the write committed but the response was lost, the console reloads the resulting authorization ID and generation, then requires the user to rotate with a new idempotency key or revoke it. Reusing an idempotency key with different terms is a conflict. These recovery operations remain inside the passkey/action-bound console; there is no builder API route for them.

Manage active sessions

GET /v1/auth/sessions returns at most the 100 most recent sessions owned by the authenticated wallet. Rows contain only an opaque UUID, creation/last-seen and expiry timestamps, nullable revocation time, and current; Aura never returns the JWT, CSRF secret, token digest, or a credential fingerprint.
Single-session revocation is intentionally enumeration-safe and idempotent: missing, already-revoked, and foreign UUIDs all return 204. Revoking the current session clears its cookie. revokeAllSessions() immediately invalidates every cookie and bearer token for that wallet, including the presented session. Cookie-authenticated logout and revocation are writes and require the current x-csrf-token. Bearer callers are CSRF-exempt. POST /v1/auth/logout revokes the exact presented session (so copied tokens stop working), clears browser cookies, and still returns 204 when no active session is present.

Session endpoints

Raw seed export is deliberately unavailable. Deleting an Aura wallet account must use the dedicated account-destruction/recovery policy; it is not a way to reveal custody material.
Last modified on August 11, 2026