Vercel's AI Gateway now shows every agent session, and keeps it on one provider
SummaryAI Gateway logs now group requests into sessions, with the coding agent behind each one, its cost and its cache hit rate. Session affinity, on by default, tries to keep each conversation on the provider that already holds its prompt cache.
· MODEL Editors · 2 min read
Some links may be affiliate links. Disclosure

AI Gateway is Vercel's single endpoint for calling models from many providers. On October 18, Vercel added a Sessions view to its logs. Instead of a flat list of requests, you see conversations: each row names the coding agent or app that ran the session (Vercel's examples are Claude Code, Codex and Cursor), plus its cost, the models and providers it used, and how much of its input was read from cache across every turn.
Open a session and you get its cache hit rate, duration and path. The path lists each turn with its model and timing, and names the provider serving the session along with any earlier ones. You can filter sessions by number of turns, client, model, provider, authentication or cost. Single-turn sessions are hidden until you clear the minimum-turns filter.
Why the cache matters. A provider's prompt cache lives with the provider account that served your request. If the next turn of a long agent conversation goes to a different provider, the cache is cold and you pay full price for the whole prompt again. Session affinity, which Vercel's docs say is on by default for text and chat requests, remembers which provider served a session's last turn and tries it first next time. It only reorders providers your routing settings already allow, and it never promotes a provider the gateway treats as down. Pins expire shortly before the provider's cache would: about 10 minutes for OpenAI and Azure, an hour for DeepSeek, and 5 minutes for most others, including Anthropic and Google, unless you ask for a longer cache.
Who it's for: teams running coding agents or multi-turn assistants through AI Gateway who want to see what each session cost and whether long conversations are actually hitting the cache.
The caveats, from Vercel's own docs. If you don't send a session ID, the gateway guesses one by hashing the opening of the conversation: the first system message, the first other message and the tool list. Two conversations that start the same way, such as a script that opens every run with "Begin the task.", get lumped into one session. The fix is to send your own sessionId in providerOptions.gateway, or the same x-session-id header, on every request. Affinity also puts the pinned provider ahead of a custom provider order you set; turn it off per request with sessionAffinity: false if you need your order kept exactly. Routing details in the logs are kept for 30 days.
On price, Vercel says AI Gateway adds no markup or platform fee on tokens: you pay the provider's list price, and the free tier includes $5 of credit a month on a subset of models.
MODEL has not used AI Gateway's Sessions view. Everything above comes from Vercel's changelog and documentation, read on October 18. Our site is hosted on Vercel; this is not sponsored and has no affiliate links.
Sources
- AI Gateway logs now show session affinity (changelog, Oct 18, 2026)
Vercel
- AI Gateway Session Affinity (docs)
Vercel
- AI Gateway Request Logs (docs)
Vercel
- AI Gateway Pricing (docs)
Vercel
- Announcement post
Vercel Developers on X
FREE · EVERY WEEK
The top AI tools this week, tested.
Every week MODEL's editors pick the AI tools worth your time, try them hands-on, and tell you what's good, what's not, and who it's for. Free, in your inbox.
Free. Unsubscribe anytime. Our picks are editorial and can't be bought.
The weekly three is editorial. A subscription does not buy a place in it.
Continue

Hot take
A login screen is not a lock
A South African coffee chain's internal dashboard, reported as vibe-coded, showed a login page while shipping franchise contacts and business data to anyone with the URL. The fix is not to stop using AI. It is one check that takes five minutes.
· MODEL Editors

Tools
Google Research lets the agent fix its own harness
Harness², now open source under Apache 2.0, has an agent rewrite the prompts, tools, skills and memory around a frozen model for each new task. The gains are real on Google's chosen benchmarks. So is the extra compute.
· MODEL Editors

The test
Headroom, on the stand
The open-source context compressor for coding agents cut our test log by 83% and a JSON response by 66%, and kept the error we planted. It left our code file alone, and one of its own labels miscounted.
· MODEL Editors