Skip to main content
Nano ledger recording is not an on-chain payment or Circle x402 settlement. Authenticated mainnet execution is not verified. Creating a row is not payment evidence. Read availability.

Authentication

POST/GET /api/payments/nano and POST /api/payments/nano/settle use the merchant/internal-key wrapper: a verified active merchant key/session or active internal service key. A consumer cookie alone does not satisfy this wrapper. Recording and normal single-pair settlement require control of agentSCA, the debited payer. Merchant-side control alone is insufficient. Internal platform automation has a separate, explicitly configured authorization path; no arbitrary payer may fall back to a shared wallet.

Record — POST /api/payments/nano

Send JSON fields agentSCA, merchantSCA, amount, optional description, currency and tokenAddress.
  • Parties must be EVM addresses. Amount is a positive human decimal with at most 6 decimals, capped at 10,000,000.
  • Default currency is USDC; supported USDC/EURC identity is server-resolved and symbol/address mismatch rejected.
  • A historical merchant address can be mapped to the current merchant wallet; unknown destinations stay unchanged.
  • Payer ownership and spend-limit checks run before settled: false recording.
  • Missing explicit production platform configuration can fail the path; do not substitute a testnet default.
Record success includes success, nano, unsettledBalance, unsettledCount, currency, tokenAddress, readyToSettle and message. readyToSettle checks the current 1.0 token threshold, not a payment receipt. The record handler does not invoke the shared nano limiter; limits elsewhere are not universal path-prefix policy.

Summary — GET /api/payments/nano

Required query fields: agentSCA, merchantSCA. Optional currency/tokenAddress filters one token. This is authenticated but does not perform the POST payer-control gate or settle any rows. The response includes total, count, ageMs, shouldSettle, payments, thresholdUSDC, currency, tokenAddress, decimals, mixedTokens and tokenGroups. Unfiltered total may combine currencies and must not be used as one transferable amount. tokenGroups separate canonical tokens. Summary eligibility is threshold ≥1.0 or age ≥60 seconds; execution behavior below is more specific.

Settle — POST /api/payments/nano/settle

Normal single-pair settlement checks threshold ≥1.0, not merely age. autoSettle uses per-token summary threshold/age eligibility when an owner-operated runner actually calls it. There is no automatic timer established by recording. The payer must resolve to its registered Circle wallet. The explicit platform payer is internal-only and requires production configuration; no unknown payer inherits it. The receiver is resolved to the merchant’s current wallet at transfer time. This route uses the shared nano rate-limit tier, token-separated atomic row claims, tracked SUBMITTED transaction resumption and stale-lock recovery. Those source mechanisms are not a blanket proof against every crash/concurrent takeover. No database-backed contention or live Circle nano settlement was proven here.

Settlement responses

  • A single-token result returns success, batchRef, txHash, explorerUrl, total, count, resumed, currency, tokenAddress, totalSettled and paymentsCount.
  • A mixed-token result returns success: true, mixedTokens: true and per-token settlements. Inspect each item’s success; the top-level flag does not mean every token batch succeeded.
  • Internal auto-settle returns settledPairs, failedPairs and individual results, not a single transaction.
  • Confirmed batch rows use SETTLED and settled: true; this is distinct from checkout’s SUCCESS state.
Wrong payer control returns 403; threshold failure is 400; missing registered Circle wallet and uncertain/failed transfers can return 500. A timeout does not prove that no transaction was created. Inspect the existing Circle ID, receipt and claimed rows before a retry. nano.batch_settled webhook fields include batch/parties/token, totalSettled, paymentsCount, hash, explorer URL and settledAt. Deliveries are unsigned/best-effort, not authenticated settlement evidence.