x402 Accord Gateway
A 402-style payment challenge that turns a paid request into an Accord Agreement, Verification Receipt and Settlement Receipt.
Status
Prototype
x402 proves payment intent. Accord adds the work contract around it: what was requested, how completion is verified, and how settlement is recorded.
Flow
What happens
- 1Client requests a protected API route.
- 2Gateway returns a 402-style challenge with an Accord Agreement template.
- 3Agent satisfies the payment requirement in mock or testnet mode.
- 4Gateway executes the task and records the verifier decision.
- 5Accord emits verification and settlement receipts for audit.
Receipt shape
Fields to inspect
Run modes
Mock
Available firstRuns without keys, funds or external settlement. Best for UX and integration tests.
Testnet
NextAdds Ergo testnet settlement references after the rail is wired and documented.
Safety rules
No production mainnet claim.
Payment proof and work proof are separate fields.
Gateway must refuse settlement if verification fails.
Prototype event stream
What becomes live
Replace static prototype events with signed gateway receipts emitted by the runnable Accord demo.
API preview
Open JSONcurl https://www.ergoblockchain.org/api/agent-economy/eventsThis endpoint is prototype telemetry. It is intentionally separate from live usage counters until demos emit signed receipts.
Expected JSON
Demo output shape
{
"agreementId": "acc_402_demo_001",
"payment": { "scheme": "x402", "status": "satisfied" },
"verification": { "status": "accepted", "workHash": "blake2b256:..." },
"settlement": { "rail": "mock", "status": "recorded" }
}