API Reference & Endpoints
All production URLs use https://facilitator-testnet.allunity.ai. JSON request bodies must be ≤ 16 kb and use Content-Type: application/json.
Method | Path | Purpose |
|---|---|---|
|
| Simulate a payment without on-chain effects. |
|
| Submit the authorized transfer on-chain. |
|
| List supported schemes/networks and signer addresses. |
POST /verify
Simulates the payment without spending gas. Request and response are the same shape as /settle, except that /verify returns a VerifyResponse.
Request body
Field | Required | Description |
|---|---|---|
| yes | Signed payment payload (v2 shown above). |
| yes | Requirements the client accepted. |
curl -s -X POST https://facilitator-testnet.allunity.ai/verify \
-H "Content-Type: application/json" \
-d '{
"paymentPayload": { "x402Version": 2, "accepted": { ... }, "payload": { ... } },
"paymentRequirements": { "scheme": "v2-eip155-exact", "network": "eip155:84532", ... }
}'
Response
Status | When | Body |
|---|---|---|
| Payment processed (valid or invalid) |
|
| Missing fields or schema validation failure |
|
| Missing/invalid key, revoked/suspended/expired credential, or suspended tenant under |
|
| Credential ratelimit exceeded under |
|
| Credential limiter fault under |
|
| Credential-store outage under |
|
| Unexpected server error |
|
Examples
200 valid:
{
"isValid": true,
"payer": "0xDeAdBeEfDeAdBeEfDeAdBeEfDeAdBeEfDeAdBeEf"
}
200 invalid (token not allowed):
{
"isValid": false,
"invalidReason": "token_not_allowed"
}
400 schema validation failure:
{
"isValid": false,
"invalidReason": "Invalid paymentPayload: payload.authorization.from: Required"
}
POST /settle
Verifies the payload and then submits the on-chain transfer. Responses are SettleResponse; on failure transaction and network are "".
Request body
Identical to /verify.
curl -s -X POST https://facilitator-testnet.allunity.ai/settle \
-H "Content-Type: application/json" \
-d '{
"paymentPayload": { "x402Version": 2, "accepted": { ... }, "payload": { ... } },
"paymentRequirements": { "scheme": "v2-eip155-exact", "network": "eip155:84532", ... }
}'
Response
Status | When | Body |
|---|---|---|
| Settlement succeeded |
|
| Missing fields, schema validation failure, on-chain rejection, or non-allowlisted token |
|
| Auth reject under |
|
| Ratelimit exceeded under |
|
| Settle queue full |
|
| Rate-limiter fault under |
|
| Credential-store outage under |
|
| Unexpected server error |
|
Transactions are processed with bounded concurrency; excess requests queue. A queue-full 503 means the request was not processed; retry after Retry-After: 3. A 400 means the settle was attempted and rejected, and retrying the same payload will not help.
Examples
200 success:
{
"success": true,
"transaction": "0xabcdef1234567890abcdef1234567890abcdef1234567890abcdef1234567890",
"network": "eip155:84532",
"payer": "0xDeAdBeEfDeAdBeEfDeAdBeEfDeAdBeEfDeAdBeEf"
}
400 on-chain settlement failed:
{
"success": false,
"errorReason": "transfer failed: insufficient allowance",
"errorMessage": "execution reverted: ERC20: transfer amount exceeds allowance",
"transaction": "",
"network": ""
}
503 queue full:
{
"success": false,
"errorReason": "Service temporarily overloaded, please retry",
"transaction": "",
"network": ""
}
GET /supported
Lists the scheme + network combinations, registered extension keys, and signer addresses.
curl -s https://facilitator-testnet.allunity.ai/supported
Response
Status | When | Body |
|---|---|---|
| Supported configuration returned |
|
| Auth reject under |
|
| Ratelimit exceeded under |
|
| Rate-limiter fault under |
|
| Credential-store outage under |
|
| Unexpected server error |
|
200 typical single-chain configuration:
{
"kinds": [
{ "x402Version": 2, "scheme": "v2-eip155-exact", "network": "eip155:84532" }
],
"extensions": [],
"signers": {
"eip155:84532": ["0xAbCd1234AbCd1234AbCd1234AbCd1234AbCd1234"]
}
}