SpendPreflight
api.spendpreflight.com/v1/preflight
SpendPreflight — trust and verification tools for stablecoin payments, built for AI agents and the people who run them. Payment Preflight: check an x402 challenge or cart against caller spending/sanctions rules and cached evidence. Returns allow/hold/block, reasons and a receipt. Missing/stale evidence stays unknown. No merchant fetch, signing, settlement or custody. Payee binding is a separate ch
POST
https://api.spendpreflight.com/v1/preflightUptime100% of 2 checks in 30 days
30 days agoToday
Try it
Pays from your browser wallet in USDC on Base or USDG on Robinhood Chain, whichever the endpoint takes. The provider is paid directly; failed calls aren't refunded by Fourohtwo.
The response shows up here.
Call it from an agent
// npm install fourohtwo
import { createPayer } from "fourohtwo";
// One agent key pays USDC on Base or USDG on Robinhood Chain, inside your spending rules.
const pay = createPayer({ privateKey: process.env.AGENT_KEY, maxPerCallUsd: "0.05" });
const res = await pay("https://api.spendpreflight.com/v1/preflight", {
method: "POST",
headers: { "content-type": "application/json" },
body: JSON.stringify({"challenge":{"accepts":[{"amount":"10000","asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","network":"eip155:8453","payTo":"0x0000000000000000000000000000000000000001","scheme":"exact"}],"resource":{"url":"https://api.example.com/data"},"x402Version":2},"context":{"spent_today_usd":0},"rules":{"hold_above_usd":0.25,"max_per_payment_usd":1,"new_domain_days":30}}),
});
console.log(await res.json());Example input
{
"challenge": {
"accepts": [
{
"amount": "10000",
"asset": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
"network": "eip155:8453",
"payTo": "0x0000000000000000000000000000000000000001",
"scheme": "exact"
}
],
"resource": {
"url": "https://api.example.com/data"
},
"x402Version": 2
},
"context": {
"spent_today_usd": 0
},
"rules": {
"hold_above_usd": 0.25,
"max_per_payment_usd": 1,
"new_domain_days": 30
}
}