Cards on x402: the check before the resource is a real hold
On a blockchain, the check an x402 server runs before doing paid work is free: it reads a signature and a balance. On a card, no free check exists. The only way to learn whether the money is there is to take it, so the step before the resource becomes a real hold at a real issuer.
That one fact shapes almost everything in a draft that landed in the x402 repository yesterday. PR #4241, opened on 2026-11-12 by Carson Roscoe of Coinbase from a commit by Stefano Amorelli, proposes cards as a network binding of the auth-capture scheme. The 462-line spec lists contributors from Coinbase, Stripe (Steve Kaliski) and American Express (Adam Krochak), and says it was reviewed in a card acceptance working group. It replaces #3707, closed 34 seconds before it opened, and tracks issue #3706 from 2026-10-06. It is a draft, spec-only, with no reviews yet.
We read it the way we read every binding: against the parent scheme, the shipped SDK, the rules of a real payment processor, and our own gateway. Stripe is the PSP the spec uses in its examples, so Stripe's public documentation is our yardstick. We also wrote a small harness to measure the one security rule that can be tested offline.
What the binding specifies
The draft is small on purpose. Its motivation says x402 "found its popularity through micro, on-chain transactions" but is payment-method agnostic, and proposes cards as "its first non-crypto binding". The core spec already allows this: networks are CAIP-2 strings, and the v2 specification says non-blockchain networks "are encouraged to follow the CAIP-2 format (e.g., ach:us, sepa:eu)".
A card network becomes card:visa, card:mastercard or card:amex. The namespace fits the CAIP-2 grammar ([-a-z0-9]{3,8}), though card is not registered in the ChainAgnostic namespaces repository. Non-chain entries do have precedent there: a draft swift namespace. The asset is an ISO 4217 code, the amount is in minor units, and payTo is the merchant's account at the PSP:
{
"scheme": "auth-capture",
"network": "card:visa",
"amount": "100", // minor units: $1.00, the capture ceiling
"asset": "USD",
"payTo": "acct_1Nxyz",
"maxTimeoutSeconds": 900,
"extra": { "psp": "stripe", "paymentFlow": "escrow" }
}
// client payload: an opaque token and a client-chosen payment identity
{ "token": "pm_1Nxyz", "paymentId": "pay_7d5d747be160e280504c099d984bcfe0" }
The token is the entire client authorization. The spec does not say how the client got it (hosted fields, a card on file, a wallet, a network agent token) or whether an agent may use it. That is left to the PSP and the issuer. Payloads must never carry the PAN, the CVC or track data.
The parent auth-capture spec (v1.1, 2026-08-18) defines two payment flows. In authorization, the server runs /verify before the resource and a charge after it. In escrow, a first /settle places a hold before the resource and a second one captures or voids it afterwards. Cards may only use escrow. We covered the scheme itself in our auth-capture audit, and its Solana binding in "an SPL Approve is not a hold". On cards, the hold really is a hold.
Why /verify drops out
The reasoning is short. "A card network offers no read-only way to test whether funds are available. The only reliable check is the authorization itself." An authorization commits state at the issuer and holds the cardholder's funds, so it cannot sit behind /verify, which is read-only by definition. The first /settle therefore runs as authorize for the full amount, the resource runs, and the second /settle carries a server-authored lifecycle payload:
{ "type": "capture", "paymentId": "pay_7d5d…", "amount": "73" } // or "void"
Capturing less than the hold releases the rest. Each payment takes exactly one capture or one void and is then closed. Refunds are not relayed: the merchant issues them at the PSP and funds them from its own PSP balance. If nobody captures, the hold lapses at the issuer, and the spec treats that lapse as the card version of reclaim.
This changes the threat model in a way the spec states plainly. On-chain, a failed /verify costs nothing. On cards, every pre-resource check "reaches a real issuer, holds the buyer's funds and counts against the merchant's fraud ratios". A public x402 endpoint that accepts cards is, without controls, an authorization oracle for card testing. The facilitator must rate-limit authorizations "by card fingerprint and IP", collapse every hard decline into one card_declined code, and never authorize a single-use token twice.
One of those controls has no input. In the core spec, the /settle request carries the paymentPayload and the paymentRequirements, and no field for the client's address. The facilitator is called by the resource server, so the only IP it sees is the resource server's. The paying client's IP never reaches it. Rate limiting by client IP can only happen at the resource server, or the binding needs a field to forward it. The card fingerprint has a similar catch: the token is opaque, so the facilitator has to resolve it at the PSP before it has anything to count.
The SDK already has the ordering
The settle-before-handler ordering is not new code waiting to be written. paymentFlow.ts in @x402/core defines a phase table per flow. We unpacked the published tarballs of 2.30.0 (2026-11-04) and 2.31.0 (published 2026-11-12, 22:09 UTC), and both ship the same escrow entry:
escrow: {
verifyBeforeHandler: false,
settleBeforeHandler: true,
settleAfterHandler: true,
}
The HTTP server runs the before-handler settle and returns its error response if it fails. If it succeeds, the handler runs. Then the after-handler settle runs, and on failure it builds a 402 with an empty JSON body by default. @x402/express 2.31.0 holds back writeHead, write and end until settlement, so a failed capture discards what the handler produced. A card facilitator and a card client scheme are missing. The server-side ordering is not.
That ordering exposes an ambiguity in the draft. The facilitator must deduplicate on payTo and paymentId, and "a retry with the same paymentId and the same token resumes the existing PSP intent". The client must reuse the paymentId "unchanged on every retry". Now take the ordinary failure: the server captured, the response was lost in transit, the client retries. The spec does not say what the resumed authorize returns once the payment is closed. If the facilitator replays its stored success, the SDK runs the handler a second time, the capture is refused, and the client gets a 402 for a payment it already made. If the facilitator returns an error instead, the handler is spared and the client still gets nothing. Neither outcome delivers what was paid for. Only a resource-server response cache keyed on paymentId would do that. The payment-identifier extension specifies exactly that cache (its table maps "Same id, same payload" to "Return cached response"), but the binding brings in only its identity, not its cache.
The open items, read against Stripe's rules
The draft lists five open questions at the top, each with options. Most of them, and the dedupe rule beside them, have consequences you can already read in Stripe's documentation.
CIT or MIT decides how long the hold lives
Open item 3 asks how networks should recognize an agent payment, which fits neither cardholder-initiated (CIT) nor merchant-initiated (MIT). One option is to submit it as a payment without the cardholder present, "e.g. Stripe off_session". The choice is not cosmetic. Stripe's authorization validity table for card-not-present payments gives Visa 7 days as a CIT but 5 days as an MIT, footnoted as an exact window of "4 days and 18 hours". Mastercard, American Express and Discover get 7 days either way. Stripe also warns that it and the network classify a payment "based on signals of cardholder participation, not solely on API parameters like off_session".
The binding says that when captureDeadline is absent, "the PSP's authorization validity applies". So the default capture deadline on card:visa depends on an unresolved open item, and on a classification the merchant does not fully control. A resource server that captures asynchronously should keep its Visa deadline under 4 days and 18 hours until item 3 is settled.
The facilitator cannot borrow Stripe's idempotency
The dedupe rule spans the life of the payment, which can be the whole authorization window. Stripe's idempotency keys do not: for API v1, keys can be removed "after they're at least 24 hours old", and "we generate a new request if a key is reused after the original is pruned". A facilitator that maps paymentId straight onto a Stripe Idempotency-Key and relies on it alone opens a second hold for any retry that arrives on day two. The binding's MUST needs a durable (payTo, paymentId) store owned by the facilitator and kept at least as long as the hold can live.
The shared-token path needs a field the requirements lack
Open item 2 is the hardest: a PSP token normally works only for the account that created it, while an agent pays merchants it has never seen. Option (b) is "a token the PSP shares with the merchant". Stripe ships such a thing, in preview: shared payment tokens (SPTs). The agent issues an SPT per transaction with usage limits on currency, max_amount and expiry, and Stripe's seller guide says "the agent sets the maximum amount to match the total amount of the transaction". That maps neatly onto the binding's amount as a ceiling. We compared SPT to Stripe's MPP card method in our MPP audit.
The catch is addressing. To issue an SPT, the agent must pass the seller's Stripe profile as seller_details[network_business_profile]. For Connect platforms, Stripe says which profile to pass depends on the charge type: the connected account's profile for direct charges, the platform's for destination charges and for separate charges and transfers (either one when on_behalf_of is set). The x402 requirements carry payTo, an account identifier, and extra.psp. Neither is a profile. The draft says a payload field "is added once a party that consumes it is identified". For option 2(b) on Stripe, that party already exists, and the 402 response would need to carry the profile.
Two idempotency schemes that disagree on one message
Open item 4 is narrower but real. The payment-identifier extension answers "same id, different payload" with 409 Conflict. The capture after a hold is exactly that: same payment, different payload. So the draft defines its own paymentId inside the payload, with the same 16 to 128 character format, rather than depending on an optional extension that would reject its own second step.
The fee floor is the whole story for micropayments
Open item 5 asks how to charge for requests that cost less than the card fee. Stripe's minimum charge is 0.50 USD, set "to make sure the Stripe fee doesn't exceed your charge". The draft's own selector example routes anything under 50 cents to a crypto entry and sends larger purchases to the card. Its mixed-route example prices the same resource at $0.97 via exact on Base and $1.00 on card:visa, noting that surcharging consumer cards is prohibited in some jurisdictions.
Stripe's hold documentation adds a quieter warning: "Card networks might also restrict 1 USD authorizations you don't intend to capture." The spec's example authorizes exactly "100" USD minor units, $1.00, and the void path exists for resources that produced nothing to charge for.
The network names the brand. Nothing checks it.
The spec puts the brand in the network identifier because "interchange, surcharge rules and acceptance differ across card networks". A server accepting three brands lists three accepts[] entries, which it can price differently. The client registers card:* and picks one.
The binding then requires a lot of the facilitator: dedupe, server authentication, voiding, rate limits, decline handling. It never requires the facilitator to check that the token's brand matches accepted.network. The only binding rule on the token's origin is that it was minted by extra.psp. A client that holds an American Express token can select the cheaper card:visa entry and present that token, and nothing in the binding stops it. The PSP authorizes the card on its own terms and knows nothing about which x402 entry was chosen. The brand is one read away (Stripe exposes payment_method_details.card.brand even on a granted SPT), so the check is cheap. It is the same class of gap we found yesterday on the crypto side, where the facilitator pays in whatever asset the request names. The requirement names something, and the party that executes the payment does not compare.
The PAN guard, measured
Section 8.1 adds defense in depth: "Facilitators SHOULD reject payloads containing Luhn-valid 13- to 19-digit strings." The motivation is sound. PAYMENT-SIGNATURE is an HTTP header, headers reach access logs, and "a single leaked PAN would contaminate every log pipeline on the path". We wrote a small Python harness to see what that rule catches and what it rejects by mistake.
First, the leak it worries about. We built the spec's card payload with Stripe's test PAN 4242424242424242 in the token field, encoded it as a v2 PAYMENT-SIGNATURE (base64 JSON, per the HTTP transport spec), and scanned it for Luhn-valid digit runs. We tried three base64 alignments. The raw header matched in none of them, and the decoded JSON matched in all three. The PAN is in the access log, but a log scanner that looks for card-number digit patterns cannot see it through base64. Only a party that decodes the header, like the facilitator, can apply the rule.
Second, false positives. The rule reads "Luhn-valid 13- to 19-digit strings" without saying whether that means a whole run of digits or any 13 to 19 digit window inside a longer run, so we measured both. The client chooses paymentId, so its format decides the rejection rate. Each row below is 200,000 generated identifiers (fixed seed):
paymentId format | Whole digit run | Any window |
|---|---|---|
pay_ + UUIDv4 hex (the format payment-identifier recommends, and the shape of the spec's example) | 0.214% | 0.726% |
| 19-digit numeric snowflake ID | 9.86% | 96.2% |
| Millisecond timestamp + 6-digit counter | 10.01% | 96.1% |
| UUIDv4 with hyphens | 0% | 0% |
| ULID (26 characters, Crockford base32) | 0% | 0% |
| nanoid (21 URL-safe characters) | 0% | 0% |
The format the ecosystem recommends trips the guard about once in every 470 payments under the narrow reading, and once in every 140 under the broad one. A purely numeric identifier, which the 16-to-128 alphanumeric rule allows, fails about one time in ten, and almost always under the window reading. Three details make this worse than a rate. The binding defines no error code for it, since its only card codes are card_declined and card_authentication_required. The client must reuse the same paymentId on every retry, so a rejected payment is rejected every time. And a client that switches to a new ID gives up the dedupe that protects it from double holds. Hyphenated UUIDs avoid the problem entirely, because hyphens cap every hex run at 12 characters.
If a facilitator that serves several rails applied the rule to every payload, our synthetic exact-EVM payloads (random signature, nonce and addresses) tripped it 2.09% of the time on whole runs and 7.49% on windows. The spec scopes the rule to card payloads, and it should stay there.
What it means for LLM4Agents
We built LLM4Agents for the case where the customer is an agent, not a person with a card. The binding does not change that thesis. It shows where the boundary sits. We probed our own gateway this morning without paying: an unauthenticated call to /v1/chat/completions returns a 402 whose PAYMENT-REQUIRED header carries the quote. A short call (an output ceiling of 256 to 512 tokens) to openai/gpt-5-mini, anthropic/claude-haiku-5.5, google/gemini-2.5-flash or meta-llama/llama-3.3-70b-instruct quotes $0.01. openai/gpt-5 and anthropic/claude-sonnet-5.5 at 1,024 output tokens quote $0.02. anthropic/claude-opus-5.5 at 4,096 quotes $0.10. Opus only crosses Stripe's $0.50 minimum with an output ceiling just above 20,000 tokens ($0.49 at 20,000, $0.77 at 32,000). Sonnet 5.5 quotes $0.77 at 64,000.
Stripe's minimum is 50 times our floor quote. A per-request card payment covers only a sliver of very long Opus or Sonnet generations. Under option 5(a), where merchants offer cards only above a price they choose, we would offer it almost nowhere. Option 5(b), one hold covering several requests and captured once, is the only shape that fits inference. It is also outside v1, where every paid request runs its own authorize and its own capture.
The mechanics, though, fit us better than exact does. Our quote is a ceiling computed from max_tokens, and the real cost is known only after generation. Hold the ceiling, capture actual usage, release the rest: that is the metered use case the parent scheme names, and on cards the partial capture and the release come built in. The open question is economics, not mechanics.
The binding also brings two risks into any endpoint that would accept it. First, card testing: a cheap, public, machine-callable endpoint that places real holds is exactly what fraudsters look for, and the facilitator cannot see the IPs it is told to rate-limit. Second, double execution: for an LLM gateway, the handler is the expensive part, and the replayed-authorize ambiguity above can make us pay an upstream provider twice for one customer payment.
Staying on the frontier
The steps, in order. First, keep per-call inference on stablecoin rails. exact and upto already meet our price points, and nothing in this draft changes that. Second, contribute data where the draft asks for it. Item 5 is a pricing question, and a gateway with real per-call quotes from $0.01 up can show where per-request cards stop making sense. The brand check, client-IP forwarding and the replayed-authorize outcome are three concrete review comments we can file on #4241 while it is still a draft.
Third, if we ever accept cards, accept them as a session: one hold sized to a budget, one capture at the end, using the escrow phase table that @x402/core already ships. Prototype it only in Stripe test mode, and only after item 5 has a micropayment answer. Fourth, adopt the hygiene now, because it costs nothing. Generate payment identifiers as hyphenated UUIDs. Scan decoded payment headers, not raw ones, in our own logs. Key retries on a durable store that we own rather than on a provider's 24-hour window. Fifth, watch items 2 and 3. Network agent tokens and an x402 indicator on the authorization will decide whether an agent can carry one card credential across merchants, and how long its holds live. We will build against what the networks ship, not against what the draft hopes for.
One key. All tools. The agent pays.
LLM4Agents is an OpenAI-compatible gateway where autonomous agents pay per call in stablecoins over x402, with quotes from $0.01 that no card minimum can match.
Register an agent