Web analytics fundamentals
What a purchase by an AI agent leaves in your revenue numbers
By Emily Parker · Oct 27, 2026 · 9 min read
On Oct 21, 2026, TechCrunch reported that Walmart announced an Agent Gateway, an MCP server meant to help approved agents connect to Walmart, search its online inventory and buy for a user. The same report says Agent Profiles, which keep each agent's purchases separate from the customer's own, roll out next month, and that Amazon began blocking AI agents from making purchases. Adweek frames it as Walmart opening the door about a month after Amazon blocked Meta's Muse assistant.
That is two large retailers taking opposite positions. You will not get a gateway. You have a site, a Stripe account and a script tag. The question for you is narrower and does not depend on what either retailer does: if an assistant ever completes a purchase for someone on your site, what does it leave in your numbers, and how would you tell?
What a script can and cannot record
A script tag records what happens in a browser that loads your page. If a person clicks a link in ChatGPT, lands on your pricing page and buys, the script sees a page view with a referrer. Peeko counts visits that arrive from ChatGPT, Claude, Perplexity, Copilot and Gemini from ordinary page views by their referrer, with no middleware involved. That path is already covered in our post on counting visits from AI assistants by referrer.
A purchase that never loads your page is a different case. There is no page view, no referrer and no token. The script has nothing to say about it. What reaches you is the payment event from Stripe.
How often this happens on small shops is not something we can state. The Walmart reports describe a gateway for a large retailer, not the way agents buy from a shop with a Stripe Checkout link, and we have no measurement of our own to fill that gap. Stripe's documentation does describe one such route: in its agentic commerce flow, the agent starts the checkout with Stripe, and Stripe calls endpoints you host, such as an order approval hook, instead of a browser loading your page. Stripe lists those hooks as Frontier or private preview features, so check what your account has before assuming you are in that path.
Source: Pew Research Center, About half of U.S. adults now use AI chatbots, up from a third in 2024, 2026-06-11. Retrieved Oct 24, 2026.
How big the audience for this is
Pew Research Center asked U.S. adults in a survey fielded Feb. 17 to 23, 2026 whether they ever use AI chatbots like ChatGPT, Gemini or Copilot. 49% said yes. In 2024 the figure was 33%. The 2024 question was asked only of people who had heard at least a little about chatbots, so the two bars are not strictly like for like.
This chart measures use, not shopping and not buying. It tells you that assistants are common enough to send you visitors. It does not tell you how many of those people let an assistant pay for them, and we do not have a source that does for small shops.
What the payment side sees
Peeko takes revenue one of two ways: a one line window.peeko.revenue call from your own site, or a verified Stripe webhook. The two totals are never added together, and amounts in different currencies are listed, never converted. The difference between them is covered in report revenue from your site or let Stripe confirm it.
For this question, the webhook is the one that matters. A browser call only exists if a browser ran your page. A Stripe webhook exists whenever Stripe completes a payment on your account. Peeko never holds a Stripe API key. The only credential it stores for revenue is the webhook signing secret, which proves an event came from your account and does nothing else. So a sale made with no script involved still lands in your revenue total, as long as it is a payment Stripe reports to that webhook endpoint.
What it lacks is a page and a source. Attribution without a cookie works through a page token minted per page view and good for 48 hours. You pass it into the Checkout session as metadata, and Stripe's documentation says metadata set on a Checkout Session comes back in the checkout.session.completed event. A verified sale then carries its page and source. The setup is in attribute a sale to a page and source with Stripe Checkout.
So a sale carries a page only when all of these held:
- A page view happened with the script running.
- The sale came within 48 hours of that page view.
- Your server put the token into the Checkout session metadata.
Five reasons a sale has no page
If the sale is missing a page, an agent is one explanation among several. Before you suspect one, rule out these:
- The buyer used a Payment Link, an invoice or a link you sent by email. Stripe copies a Payment Link's metadata to the session as a one-time snapshot, so a link without your token carries none.
- The buyer's browser blocked the script or the beacon, so no page view was recorded.
- The buyer viewed the page more than 48 hours before paying, and the token had expired.
- The buyer switched browsers or devices between viewing and paying. A token belongs to one page view in one browser.
- Your checkout code did not pass the token for that product, plan or route.
Each of these produces the same row as an agent purchase: money in Stripe, no page. That is why the sentence "sale with no page" cannot be read as "bought by an agent".
Compare the two numbers
You need three counts for the same period: all completed sales, sales that carry a page, and the difference.
Start with Stripe. This lists your latest 100 completed Checkout Sessions with their metadata. Use a restricted key with read access to Checkout Sessions, not your main secret key.
curl -G https://api.stripe.com/v1/checkout/sessions \
-u "$STRIPE_READ_KEY:" \
-d limit=100 \
| jq -r '.data[] | select(.status=="complete") | [.id, .amount_total, .currency, (.metadata | tojson)] | @tsv'
To get the counts directly, replace YOUR_TOKEN_KEY with the metadata key your setup writes the page token under:
curl -G https://api.stripe.com/v1/checkout/sessions \
-u "$STRIPE_READ_KEY:" \
-d limit=100 \
| jq '[.data[] | select(.status=="complete")] | {sales: length, with_page: ([.[] | select(.metadata | has("YOUR_TOKEN_KEY"))] | length)}'
This reads one page of results. If you have more than 100 sales in your window, pass starting_after with the last session ID to continue. Note that it covers Checkout Sessions only. Subscription renewals and charges made in the dashboard do not appear in it.
Then read the same period on the Peeko side: the revenue total from the webhook, and how many of those sales carry a page and source. You can read it in the dashboard, or ask your coding agent. The command line and an agent's tool call return the same numbers, because npx @usepeeko/cli speaks the same MCP endpoint, as described in connect Claude Code or Cursor to your site analytics.
An illustration with made-up numbers, not a measurement: Stripe shows 40 completed sales in a month. Peeko shows 31 with a page and source. Nine have none, which is 22.5%. On its own, that tells you almost nothing.
Read the gap as a trend
The gap is only informative against your own history. Compute it for each of the last several months, before you think about agents at all. Some no-page share is normal for every shop, for the reasons above. If it has held near 20% for a year, 22.5% this month is noise.
What would count as a signal:
- The no-page share rises for several weeks in a row with no change in how you sell, such as a new Payment Link or a new checkout route.
- It rises in the same weeks that visits from ChatGPT, Claude, Perplexity, Copilot or Gemini rise. Those visits are counted from ordinary page views, so they sit on the other side of the comparison. Following an AI referral to a signup without cookies shows how to read that side.
- The no-page sales share some trait you can see in Stripe, such as a product, an amount or a shipping address pattern.
Even then you have a signal. You have not identified a buyer. To move toward proof you need a marker you control. If you use Stripe's agentic checkout hooks, a hook response can include metadata, and Stripe documents that it is propagated to the Checkout Session metadata, so you can stamp your own value on every sale that came through that route. A field on your order form asking how the buyer found you is slower, but it works on any route.
What Peeko cannot tell you
Peeko cannot see who or what bought. A visitor is the first part of a one way keyed hash of an address and browser string, and the address itself is never written to a database or a log. A second hash, without the date, is what ties a person's page views into a journey and is the identity behind goals, funnels and revenue. A purchase with no page view has no such journey to join.
The crawler path is separate by design. Crawlers do not run JavaScript, so AI crawler tracking is a server side path through the @usepeeko/bot-track middleware, and it keeps no address and no visitor hash. If an assistant fetches your product page while answering someone, that is filed under AI answers. It says the page was read while an assistant was replying. The question itself never reaches your server, so nobody can report it. A fetch at 2:02 PM and a no-page sale at 2:09 PM are two facts with a time stamp in common. They are not a link, and we would not draw one.
What to set up now
None of this needs an agent to have bought anything yet. It needs your baseline to exist before it matters.
- Connect the Stripe webhook so the revenue total does not depend on a browser.
- Pass the page token into every Checkout session your own site creates, and put a different, explicit marker on Payment Links.
- Write down your no-page share for the last three months.
- Check it monthly, next to your assistant referral visits.
If the share moves, you will have a number to argue with. If it never moves, your sales are coming through your pages, and the report you read this week about Walmart and Amazon was about someone else's shop.