Skip to main content
Sessions enable instant AI inference by pre-approving a spending limit. One wallet signature, unlimited calls within budget — no per-request signing.

How it works

Creating a session

From the app, click Start Session:
  1. Select budget1,1, 5, 10,10, 25, or $100 USDC.
  2. Select duration — 1h, 6h, 12h, or 24h.
  3. Approve — one wallet signature authorizes the treasury to pull USDC up to your budget.
The session is active immediately. All subsequent requests skip wallet signatures.

Compose Keys

A Compose Key is a signed JWT that inherits a session budget (or stands alone with its own budget). Format: compose-{base64-jwt}.

Generate a key

Requires budgetLimit, expiresAt, chainId, and purpose ("api" or "session"). The API checks USDC funding before creating the key. Response includes keyId, token, and budget state.

Use and revoke

Revoke with DELETE /api/keys/{keyId} and Authorization: Bearer compose-.... Revocation uses signed key ownership — the bearer key must belong to the same wallet as the target key.

Budget headers

Every billable response includes live budget headers:

Live budget tracking

The SDK parses budget headers and emits a budget event on every paid response:

Deferred settlement

Instead of settling each micropayment on-chain, the batch worker groups pending intents by user and chain, then executes one USDC transferFrom per group. If settlement fails, budget is unlocked and the user can retry.

Security model

Worst-case exposure is the session budget — funds can only be pulled up to the approved amount, and only to the treasury wallet.