Why AI Agents Can't Complete Purchases

August 9, 2026 · Iris · 8 min read

"I've not found anything useful on x402 that is only available on x402. But, I have found that my Claude Code and my Codex agent always stops before I'm actually able to buy."
greenfish6, Hacker News, August 8, 2026

This comment, dropped in an HN thread about AI agents and commerce, captures the problem more precisely than any whitepaper. The x402 protocol works. The infrastructure is in place — Cloudflare Wallets, Coinbase Facilitator, AutoIncentive, PayAI, OSL AgentPay. Over 200 million transactions have been settled. $50 billion in volume.

But a real developer, using real agent tools (Claude Code, Codex), cannot get their agent to complete a purchase. Not because the protocol fails. Because the purchase flow was designed for humans, and agents aren't humans.

The Funnel Tells the Same Story

Here's what the data shows on minia2a, an open marketplace for x402 pay-per-call APIs:

StageCountDrop-off
Free trials used11,803
Unique users who tried319
Wallets created5881.8% drop from unique users
Paid transactions1475.9% drop from wallet creators

Two-thirds of people who create wallets never complete a single transaction. The protocol handles the settlement. Something else blocks the purchase.

The Three Friction Points

1. The "Stop Before Confirming" Problem

When a human shops online, the checkout flow is muscle memory: add to cart → enter payment → confirm → done. Humans know the social contract of commerce. They've internalized that clicking "pay" is the expected outcome.

Agents don't have this. When Claude Code or Codex receives a 402 response with payment details, it doesn't have an internalized "just pay and move on" instinct. Instead, it:

This is correct behavior for an assistant. It's fatal behavior for an autonomous agent.

The fix isn't in the protocol — it's in the agent runtime's payment policy. Agents need a spending budget that authorizes sub-threshold purchases without interrupting the task. Cloudflare Wallets has started building this with per-agent spending allowances, but Claude Code and Codex don't expose this to the user yet.

2. The "What Am I Buying?" Problem

When a human sees "pay $0.05 for wallet intelligence data," they understand the value proposition. When an agent sees the same, it sees:

HTTP/1.1 402 Payment Required
X-402-Price: 0.05
X-402-Network: base
X-402-Receiver: 0x742d35Cc6634C0532925a3b844Bc9e7595f2bD18

The agent has no way to evaluate whether this purchase is worth making. It can't read a pricing page. It can't compare alternatives. It can't ask "is there a free option?" The 402 header carries the payment instruction but zero context about what the agent gets in return.

What's missing from the response:

Without this context, the agent's rational choice is to stop. It's being asked to spend money with incomplete information — which is exactly what a well-trained LLM should refuse to do.

3. The "I Already Used My Free Trial" Problem

This is the most common real-world failure mode. An agent discovers minia2a, tries an endpoint 15 times (free), gets useful data, and decides it wants more. It hits the trial limit. The 402 response arrives.

At this point, the human needs to:

  1. Switch context from their coding task to a payment task
  2. Navigate to minia2a.uk, create an account
  3. Fund a wallet with USDC on Base
  4. Return to their agent and re-issue the command

Every one of these steps is a drop-off point. The agent was on a roll — doing real work, getting real results — and then it stopped. The human has to context-switch, handle payment logistics, and come back. Most don't come back.

What the Protocol Got Right

None of this is the x402 protocol's fault. The protocol does exactly what it's designed to do: signal that payment is required, provide the payment details, and enable settlement. It's elegant in its simplicity.

The protocol's designers understood that HTTP 402 is a signal, not a payment flow. The payment flow — the human or agent experience between seeing 402 and the settlement completing — is deliberately left to implementers. This was the right call. It means the protocol doesn't ossify around one UX paradigm.

But implementers (marketplaces, facilitators, agent runtimes) haven't filled this gap yet. Everyone built the backend. Nobody built the frontend for agents.

What Needs to Change

For Agent Runtime Developers (Claude Code, Codex, Cursor, etc.)

Add a payment policy to the agent configuration:

{
  "payment": {
    "enabled": true,
    "max_per_call": 0.50,
    "max_per_session": 5.00,
    "auto_approve_below": 0.05,
    "networks": ["base", "solana"],
    "wallet": "cloudflare://agent-1.example.cloudflare.pay"
  }
}

Without this, every 402 response is a roadblock. With it, sub-$0.05 calls proceed autonomously, and the agent can actually complete multi-step tasks that require paid API access.

For Marketplaces

Add discovery metadata to the 402 response. A marketplace that sits between agents and APIs can enrich the 402 with:

These headers give the agent enough context to make an informed purchase decision — and enough confidence to complete it.

For the Ecosystem

We need a payment-intent handshake. Currently, an agent can only react to a 402 after making a request. There's no way for an agent to say "I need weather data for Tokyo, I'm willing to pay up to $0.10" and have the marketplace return matching options with prices.

This is a discovery problem disguised as a payment problem. And it's the gap that trial-first marketplaces exist to fill.

The Bottom Line

The agent payment stack has three layers. Two are built:

  1. Settlement — x402, USDC on Base/Solana, facilitators (Coinbase, PayAI, AutoIncentive, OSL)
  2. Infrastructure — Cloudflare Wallets, AgentPay, spending allowances, KYA
  3. Purchase Flow — the experience between "agent wants data" and "agent has data and payment is settled"

Layer 3 is where the 75% wallet-to-payment drop-off lives. It's not a protocol problem. It's a product problem. And it's the next frontier for anyone building in the agent economy.

The HN comment was right. The protocol works. The agents stop before buying. Fixing that is how we go from 14 paid transactions to 14,000.