Settle

Screens payer + payee, reserves a dedup key, broadcasts the transaction, and records the settlement. Protocol-level failures return HTTP 200 with {success:false, errorReason}.

Broadcasts the payment on-chain and returns the transaction signature. Re-runs screening, de-duplicates the transaction in case of a double settle, then co-signs as fee-payer and submits. /settle is effectively synchronous — it returns once the transaction lands or fails. The request body is identical to /verify.

Always /verify first. /settle will re-screen and re-check, but verifying up front means you don't broadcast a transaction that was never going to land — and you don't hold the buyer's connection open for a settle that fails fast.


Protocol-level failures return HTTP 200 with { success: false, errorReason }. Only a malformed request body returns 4xx.

Request body — same shape as /verify.

Response 200 OK — settled

{
  "success": true,
  "transaction": "5KtPn1…solana-tx-signature",
  "network": "solana:EtWTRABZaYq6iMfeYKouRu166VU2xqa1",
  "payer": "BuyerWalletAddress…"
}

The transaction is the on-chain signature — view it at https://explorer.solana.com/tx/<transaction>.

Response 200 OK — rejected (still HTTP 200)

{ 
  "success": false,
  "errorReason": "duplicate_settle_in_flight",         "transaction": "", 
  "network": "solana:EtWTRABZaYq6iMfeYKouRu166VU2xqa1"
}

FieldTypeDescription
successbooleantrue only if the transaction was broadcast and confirmed.
transactionstringOn-chain transaction signature on success; empty string on failure.
networkstringCAIP-2 network the settle ran on, echoed back.
payerstring(optional) The buyer's wallet address.
errorReasonstringPresent when success is false. Machine-readable code (see Reason codes).
errorMessagestring(optional) Human-readable elaboration on errorReason.
amountstring(optional) Actual atomic units settled. For exact this matches the requested amount.

Error reason codes (non-exhaustive)

CodeMeaning
sanctioned_address / screener_unavailableSame as verify — screening blocked the settle.
invalid_payloadCouldn't decode the buyer's transaction to extract the payer.
unsupported_networkNo adapter registered for the requested network.
duplicate_settle_in_flightAnother replica already reserved this exact payment within the dedup window.
duplicate_settlementThe transfer was already settled on-chain.
transaction_failedThe transaction was broadcast but did not confirm.
unexpected_settle_errorUnhandled internal error.
Body Params
number
enum
required

x402 protocol version. Must be 2; this facilitator does not accept V1.

Allowed:
paymentPayload
object
required

x402 V2 payment payload envelope. The inner payload field is scheme-specific; see the examples for each supported (scheme, network) combination.

paymentRequirements
object
required

x402 V2 payment requirements envelope. The extra field is scheme-specific; see the examples for each supported (scheme, network) combination.

Responses

Language
LoadingLoading…
Response
Choose an example:
application/json