v13

latestOpenAPI 3.1.0Apache-2.0raw.githubusercontent.com2026-04-23163074.4 KB
Payment (x402)

Poll (or long-poll) a payment session

get/api/payment-status/{sessionId}

Path parameters

sessionIdstring required

Query parameters

waitboolean

When true, the server blocks up to 60 seconds waiting for the session to transition to a terminal state (completed, failed, expired). Useful to avoid tight-loop polling.

Response

Payment session state

session_idstring required
status'pending' | 'completed' | 'failed' | 'expired' required
amountstring required

Amount as string to avoid float precision

assetstring required
networkstring required
pay_tostring required

Wallet address to pay

created_atstring date-time required
expires_atstring date-time
capture_urlstring uri

Human-facing payment URL

payerstring

Payer wallet address, set on completion.

tx_hashstring

On-chain transaction hash (when status = completed).

completed_atstring date-time

Example response

{
  "asset": "USDC",
  "network": "base-sepolia"
}