AI agents pay for APIs in two main ways. The older way is an API key tied to an account, often with prepaid credits. The newer way is per-request payment: the server replies with HTTP 402 Payment Required, the agent pays, usually in a stablecoin, and retries the request. Site owners need something worth selling and a wallet.

Say you run a small publishing site full of useful, well-organized research. AI agents now visit it constantly, reading pages and pulling data for people who will never see an ad or join a mailing list. The publisher gets the server bill and nothing else. The only way to charge is to build an account system, issue keys, collect card details and send invoices, which is more work than the content is worth, and an automated agent cannot fill in a signup form anyway. So the choices look like giving everything away or blocking everyone. The turn comes when the publisher stops thinking about subscriptions and starts thinking about a single request. What if the page itself said what it costs, and an agent could pay on the spot and carry on? That one idea changes the question from who is allowed in to what each request is worth.
How do AI agents pay for APIs today?
I am an MBA who builds WordPress and AI products, so I look at this as a business model first. Right now, nearly every API follows the same pattern. A person signs up, gets an API key, and either adds a card or buys prepaid credits. The key goes into the agent’s configuration, and every call is charged to that account.
It works well when a human decides in advance to use one provider. It works badly when an agent needs to find and use many services on its own, because each one needs its own signup, its own key and its own balance. The x402 site describes this traditional process as account setup, KYC approval, prepaid credits and API key management.
API keys and prepaid credits versus per-request payment
The difference is when the payment relationship begins.
- Keys and credits: the relationship is set up before the first request. A person is involved, the balance is held in advance, and the key must be stored and protected.
- Per-request payment: the relationship starts with the request. The price is stated when the agent asks, the agent pays, and access follows. No account is created in advance.
Neither is better in every case. If you serve a handful of known customers who need a steady relationship, accounts make sense. If you serve many unknown software clients that each make a few calls, setting up accounts is friction that costs you sales.
What is HTTP 402, and why does it matter here?
HTTP 402 Payment Required has been part of the web’s list of status codes for a very long time, but it never had a defined job. MDN describes it as nonstandard and reserved for future use. It was created to enable digital cash or micropayment systems, and it would indicate that content is not available until the client pays. MDN also notes that there is no standard usage convention, and that no browser supports it, so a browser just shows a generic error.
That history explains the opportunity. The status code exists, nobody owns it, and software clients can read it even if browsers cannot. A pay-per-request system can use it to tell an agent: this costs something, here is how to pay. You can read MDN’s page on 402 for the exact description.
How does the x402 pattern work?
I explained the standard in detail in What is x402?, so here is only the short version, based on the official x402 site. It calls x402 an open, neutral standard for internet-native payments, meant to support agentic payments at scale. The flow has three steps:
- The server is set up to require payment for certain endpoints.
- A request arrives without payment, and the server returns HTTP 402.
- The client pays and retries the request.
The site contrasts this with the traditional route. An AI agent sends a request, receives a 402, pays instantly with stablecoins and gets access without signups or stored keys. It lists EVM-compatible chains and Solana as supported and names stablecoin payments as the primary use case.
Why stablecoin settlement?
Card networks assume a person, a billing address and a minimum amount that makes the fee worth paying. An agent buying one small piece of data does not fit that model. A stablecoin is a digital token meant to track a currency, and it can be sent from one software party to another over the internet without either side opening an account with the other. That is why the x402 site treats stablecoins as the main use case. For a site owner, it also means the money can arrive in a wallet you control, instead of sitting with an intermediary.
What are the risks to think about?
This is early. MDN says 402 has no standard convention, so different systems behave differently. The pilot I am describing below runs on a test network, with test tokens that have no monetary value. Treat any pay-per-request idea as an experiment, with small scope and clear limits, until you have seen how real agents behave on your own content.
What does a site owner need to accept agent payments?
Strip away the technical vocabulary and the list is short:
- Something an agent would pay for. A useful API, structured data or content that is hard to get elsewhere.
- A wallet to receive funds. You should control it, not a third party.
- A way to answer unpaid requests. The server needs to return a payment prompt, not just a blocked page.
- A decision about which content is free. Most sites will keep their public pages open and charge only for the valuable endpoints.
- Clear records. You should know what was requested, what was paid and where the money went.
Most owners can do the first and second today. The third is where WordPress site owners need help, since few of us want to hand-write payment middleware.
Where Agent Pay by PayZiip fits
Agent Pay by PayZiip lets AI agents pay your WordPress site per request for APIs and content, in USDC, straight to your wallet. It is a testnet pilot and it is coming soon, so it is not yet a live product. During the pilot it uses test USDC, which has no monetary value.
On money handling, the product page says payments go to an on-chain split for your wallet, and that PayZiip never holds your funds. Listings can also appear on the AIplusAPI marketplace, which is coming soon, where agents can look for APIs and data to buy per request. You can see the details on the PayZiip products page.
Get the free explainer
The landing page is not live yet, so I put the essentials into a short guide you can read in a few minutes. Download the free Agent Pay x402 explainer.
Frequently asked questions
How do AI agents pay for APIs?
Today most do it with an API key tied to an account, often backed by prepaid credits. A newer pattern lets the agent pay per request: the server answers with HTTP 402, the agent pays, and it retries the request.
What is HTTP 402 Payment Required?
It is a status code reserved for payment systems. MDN describes it as nonstandard and reserved for future use, with no standard usage convention, so different systems use it differently.
Do AI agents need API keys?
With the traditional model, yes. The x402 site describes an alternative where an agent sends a request, receives a 402, pays with stablecoins and gets access without signups or stored keys.
Why do stablecoins come up in agent payments?
The x402 site names stablecoin payments as the primary use case. A stablecoin can move over the internet between software parties without an account being opened first.
What does a WordPress site owner need to accept agent payments?
You need content or an API worth paying for, a wallet to receive funds, and a way to answer unpaid requests with a payment prompt. Agent Pay by PayZiip is a testnet pilot, coming soon, that aims to handle the WordPress side.
If you want the explainer, comment X402 and I will send you my 1-page explainer.





Leave a Reply