anomalyco / anomalyco/opencode
Vercel AI Gateway `only` provider filter is ignored
@rekram1-node is already working on this.
Since Sep 17, 2026.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- PR merge metrics
- PR metrics pending
Description
Description
Vercel AI Gateway provider filtering still appears to be ignored in OpenCode CLI 1.18.30 + Desktop 1.18.31.
This is the same behavior previously reported in #21130, which was automatically closed after 60 days of inactivity. The original feature request was #2153.
With this config:
{
"$schema": "https://opencode.ai/config.json",
"provider": {
"vercel": {
"models": {
"zai/glm-5.3-flash": {
"options": {
"only": ["particle"]
}
}
}
}
}
}
However, Vercel AI Gateway shows that requests are actually served by other providers. I observed Baseten and Fireworks instead of Particle.
OpenCode logs confirm both requests use the expected Vercel model:
2026-09-17T09:02:43
providerID=vercel modelID=zai/glm-5.3-flash small=true agent=title
2026-09-17T09:02:44
providerID=vercel modelID=zai/glm-5.3-flash small=false agent=build
The Vercel AI Gateway dashboard nevertheless shows these requests
being served by Baseten and Fireworks despite only: ["particle"].
Expected behavior: the request should either use Particle or fail if Particle is unavailable. It should not fall back to another provider.
The current OpenCode Vercel documentation lists only as a supported routing option.
Plugins
No response
OpenCode version
1.18.30
Steps to reproduce
Add the following to the OpenCode config:
{
"$schema": "https://opencode.ai/config.json",
"provider": {
"vercel": {
"models": {
"zai/glm-5.3-flash": {
"options": {
"only": ["particle"]
}
}
}
}
}
}
Verify the effective config:
opencode debug config
It shows:
"only": ["particle"]
Restart OpenCode.
Run:
opencode run -m vercel/zai/glm-5.3-flash "Reply only OK"
Inspect the resulting request in Vercel AI Gateway.
The serving provider is not Particle. In my tests the requests were routed to Baseten and Fireworks.
I reproduced the same behavior with OpenCode Desktop and the CLI.
Screenshot and/or share link
Operating System
macOS 15.7.9
Terminal
Terminal.app
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.