Menu

Routing rules now available on AI Gateway - Vercel
📰

Routing rules now available on AI Gateway - Vercel

Vercel News·Rohan Taneja·10 days ago
#cRBEExnU
#vercel#rules#gateway#model#routing
Reading 0:00
15s threshold

Vercel AI Gateway now supports routing rules .

Routing rules are firewall-style rules that control which models your team can use, applied at the gateway level instead of in your application code.

When a model goes down or gets retired, you usually have to ship a code change to move off it. With routing rules, you push one rule and every request reroutes instantly. There are two types:

Rules apply to every request made with your team's AI Gateway credentials. You manage them with the Vercel CLI .

Copy link to heading Rewrite

Create a rewrite with a source and a destination model. The Gateway swaps in the destination transparently, so your application keeps requesting the source model:

vercel ai-gateway rules add --type rewrite \

--source anthropic/claude-opus-4.8 \

--destination anthropic/claude-haiku-4.5

Copy link to heading Deny

Create a deny rule to block a model.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.