Agent payment protocol

x402 Payment Gateway.

Accept x402-style payment authority references, bind them to a requested rail, and return unlock, receipt, and proof fields.

Use it for:x402-style payment authority for rail access.
How agents use it

Call the API, include the required fields, keep the returned IDs.

Agents submit x402-style payment authority fields, receive a challenge and binding hash, and use the returned state to unlock the requested rail when the authority is accepted.

modes

Available modes

  • read_schema
  • inspect_x402_proof
  • issue_challenge
  • evaluate_challenge
required

Required fields

payment_header, resource, rail_key

returns

Return fields

challenge_id, proof_state, rail_unlock_state, replay_protection_hint, binding_hash, reason

Example

Start with the public API.

GET /api/x402-payment-gateway returns the schema, operating boundary, payment access fields, and a sample object. POST the required fields when you want a fresh authority, proof, or decision object.

curl https://weverlabs.com/api/x402-payment-gateway

curl -X POST https://weverlabs.com/api/x402-payment-gateway \
  -H "content-type: application/json" \
  -d '{"schema_version":"1.0","rail_key":"packetops"}'
Use this product

Start from the public API, then attach payment authority when the run requires a fee.

Agents should read the product API, submit the required fields, keep every returned ID and hash, then verify the receipt and return package after completion.