POST /v1/sessions
API Reference
POST /v1/sessions
Create a verification session for identity bootstrapping. Paid tier required.
POST
POST /v1/sessions
Overview
Verification sessions let merchants bootstrap identity for agents that don’t have a wallet or operator credential. When an agent tries to perform a gated action without identity, the merchant creates a session and returns the verification URL to the agent. The session returns two secrets:session_id: goes in the verification URL (user-facing)poll_secret: given to the agent for polling (never in URLs)
Request
Headers
| Header | Required | Description |
|---|---|---|
X-API-Key | Yes | Your API key (paid or enterprise tier) |
Content-Type | Yes | application/json |
Body
| Field | Type | Required | Description |
|---|---|---|---|
context | string | No | Freeform context label (e.g., “wine_purchase”) |
product_name | string | No | Product name shown during verification (max 200 chars) |
GET /v1/sessions/:token. There is no browser redirect back to the merchant; this API does not accept return_url or any payment-method metadata.
Response
Response fields
| Field | Type | Description |
|---|---|---|
session_id | string | Opaque session identifier, shown in verify_url (user-facing) |
poll_secret | string | Agent-only secret for the X-Poll-Secret header when polling |
verify_url | string | Ready-to-open URL the end user visits to complete KYC |
poll_url | string | Polling endpoint for session status |
expires_at | string | ISO 8601 session expiry (1 hour TTL) |
next_steps | object | Structured agent instructions for consuming the session (action: "deliver_verify_url_and_poll", polling cadence, step-by-step) |
agent_memory | object | Cross-merchant pattern hint: LLM-hosted agents should persist the pattern (never secrets) so future AgentScore merchants skip the cold-start flow. Also emitted on POST /v1/credentials success and on first-mint missing_identity denials |
Polling
| Status | Meaning |
|---|---|
pending | User hasn’t completed verification yet |
verified | User verified: operator_token included in response |
consumed | Token already issued to a previous poll |
expired | Session expired (1 hour TTL) |
failed | Stripe Identity verification did not succeed (unreadable ID, selfie mismatch, etc.) |
flagged | Identity verified but sanctions screening flagged a potential match: credential issuance is blocked pending manual review |
Poll response by status
Pending; user hasn’t completed verification yet:operator_token included:
consumed without the token.
Consumed; token already issued to a previous poll:
Poll response fields
| Field | Type | When present | Description |
|---|---|---|---|
next_steps | object | Always | Action guidance that varies by status |
retry_after_seconds | number | pending | Recommended poll interval in seconds |
token_ttl_seconds | number | verified | TTL of the issued operator token in seconds |
Rate limits
The poll endpoint is rate-limited to 30 requests per minute per IP. Responses includeX-RateLimit-Limit, X-RateLimit-Remaining, and X-RateLimit-Reset headers.