The agent cannot prepare a payment
- Confirm the host is
https://staging.mcp.sohopay.xyz/mcp. X402_AGENT_KEY_NOT_REGISTERED: generate a workload key and callregister_agent_workload_key, then retry the same order and idempotency key.AGENT_AUTHORIZATION_REQUIRED: open the grantconsent_urland wait untilget_agent_authorizationisACTIVE.- The borrower has no handle: finish
claim_handlebefore treating onboarding as done. - Token near expiry: call
request_borrower_token. Do not usewhoamiscopes as the refresh signal.
Capture fails
x402Versionmust be2. A V1 intent returnsX402_AGENT_VOUCHER_REQUIRED.- The bearer token must be a merchant JWT or an
sk_live_key for that merchant. There is nosk_test_key, andapi-sandbox.sohopay.xyzis not the API. - HTTP 429: you are over 30 captures per minute. Retry with the same
Idempotency-Key.
The poll never reaches CONFIRMED
CREATEDfor about a minute is the flush interval, not a failure.SUBMITTEDmeans the batch is on chain and still gaining confirmations.FAILED,TIMED_OUT, orDISPUTED: do not fulfill. Check the merchant isACTIVEin the registry, then contact support with thepaymentId.- Production will not settle. Protocol V2 is disabled there.
Credit looks unchanged
Available credit moves when the batch entry isCONFIRMED, not when the voucher is signed. Read get_outstanding_balance after that status.
Next steps
Error handling
The retry table.
Testing
A known-good staging loop.

