Why facilitators exist
Without a facilitator, every merchant would need to:- Run blockchain nodes or connect to RPCs
- Verify cryptographic signatures for each payment scheme
- Submit transactions and monitor confirmations
- Handle gas fees and failed transactions
How they work
Facilitator API
Facilitators expose four endpoints:| Endpoint | Method | Purpose |
|---|---|---|
/accepts | POST | Returns enriched payment requirements (adds facilitator-specific fields) |
/verify | POST | Verifies a payment proof without settling |
/settle | POST | Verifies and settles a payment on-chain |
/supported | GET | Lists supported schemes, networks, and assets |
/accepts
The middleware calls /accepts on startup to get the full payment requirements including any facilitator-specific fields. These are cached and returned to clients in 402 responses.
/settle
When a client sends a valid X-PAYMENT header, the middleware forwards it to /settle. The facilitator:
- Validates the payment payload structure
- Verifies cryptographic signatures
- Checks amounts, addresses, and nonces
- Submits the transaction on-chain
- Returns a settlement result with the transaction hash
Default facilitator
Corbits provides a free production-ready facilitator:Running your own
You can run a facilitator using@faremeter/facilitator. See the Facilitator guide for setup instructions.
Further reading
- Payment Schemes — What happens inside the facilitator for each chain.
- Middleware — How to configure the middleware to talk to a facilitator.