Spend firewall: allow, hold or block an agent payment before it happens
shield_checkSpend firewall for AI agents with a wallet or card, called before every payment: checks your rules (per-payment cap, daily budget reserved atomically, allow/block lists, chains, tokens, approval threshold, new merchants, kill switch), the merchant or checkout URL (preflight), the text that triggered the payment (input-guard: hidden instructions) and non-USDC tokens (token-risk). Returns allow, hold or block with reasons; with a stored policy the amount is reserved until confirm or release. 0.02 USDC base (new payers 0.02, >10 payments 0.014; 1 pack call). After: pay, then POST /shield/confirm with the reservation_id (or /shield/release if you did not pay) (the result's next field has the exact call).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"payment": "<payment>"
},
"name": "shield_check"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| policy | No | inline rules (stateless); for a daily budget and remembered merchants store them with POST /shield/policy and send policy_id | |
| payment | Yes | ||
| trigger | No | the instruction, message or page that made the agent want to pay | |
| policy_id | No | a stored policy (needs your key as X-Bundle-Token or bundle_token) | |
| payment_tx | No | Hash of a USDC transfer on Base to payTo (≥ the price, ≤ 72 h old) instead of an x402 signature. | |
| bundle_token | No | Token from buy_signal_pack, buy_subscription (pro/desk) or buy_enterprise instead of paying per call. | |
| hold_seconds | No | how long an allowed amount stays reserved (default 900) | |
| payer_address | No | Wallet you pay from: the payment-required error quotes your tier (0 payments base price (new-payer surcharge paused), 1-10 base, >10 -30 %) and, from the third payment, an upgrade with your own spend. | |
| idempotency_key | No | same key = same reservation, never reserved twice |