Agents: When a user opens an agent to chat, they see the model that's configured on the agent - regardless of whether their subscription allows them to use that model.
The Issue
When a user opens an agent to chat, they see the model that's configured on the agent - regardless of whether their subscription allows them to use that model.
Example Flow:
Free user creates an agent with
gemini-2.0-flash(a free model)Pro user (same workspace) edits the agent and changes the model to
claude-sonnet-4.5(a premium model)Free user opens the agent to chat
Free user sees
claude-sonnet-4.5in the model selector - a model they cannot useIf they try to send a message, it either:
Fails with an error at runtime, or
Works (security hole if backend doesn't validate)
The Root Cause:
The agent stores a single modelId field, and when displaying the agent to users, we show that stored model without checking if the current user's subscription allows access to it.
Expected Behavior:
When a free user opens an agent that has a pro model configured:
They should not see the pro model
They should see only the models available to their subscription (the 3 free models)
The model selector should be filtered based on the current user's tier, not the agent's stored model
Log in to comment and vote
No comments yet
Be the first to share your thoughts.