URL of the page with the issue
https://geminicli.com/docs/get-started/authentication/
Additional relevant pages:
What is the problem?
The documentation does not mention that the gemini-3.1-pro-preview-customtools model variant is only available when authenticating via Gemini API Key (i.e., an API key created from Google AI Studio, corresponding to AuthType.USE_GEMINI in the codebase).
This auth-based model restriction is enforced across the entire codebase — in model resolution (resolveModel), model routing (classifier and numerical classifier strategies), policy chains, the /model dialog UI, and the ACP client — via a useCustomToolModel flag that evaluates to true only when useGemini3_1 === true && authType === AuthType.USE_GEMINI.
Key code evidence:
Partially related issues and PRs:
What did you expect to happen?
I expected the documentation to clearly state that authentication method affects which models are available. Specifically:
- Authentication docs (
docs/get-started/authentication.md): The auth methods comparison table should note model availability differences — e.g., that gemini-3.1-pro-preview-customtools is exclusive to Gemini API Key auth (AI Studio keys).
- Model selection docs (
docs/cli/model.md): Should mention the customtools variant and its auth requirement, since users choosing models via /model or --model may see different options depending on their auth method.
- Gemini 3 docs (
docs/get-started/gemini-3.md): Already mentions gemini-3.1-pro-preview but does not mention the customtools variant or that it's auth-gated.
- Model routing docs (
docs/cli/model-routing.md): Routing behavior (policy chains, classifier strategies) differs by auth type, but this is not documented.
Additional context
From code analysis, what can be confirmed is:
| Auth Method |
Model used for Gemini 3.1 Pro |
| Gemini API Key (from AI Studio) |
gemini-3.1-pro-preview-customtools ✅ |
| Other auth methods |
gemini-3.1-pro-preview (the customtools suffix is not applied) |
Note: The codebase gates the customtools variant strictly on AuthType.USE_GEMINI. It is unclear whether other API key-based flows (e.g., a Google Cloud API key used via Vertex AI auth) would or should also qualify. This issue focuses on the confirmed behavior: only AI Studio API keys trigger the customtools model selection.
This discoverability gap could cause confusion for users who see different models listed in the /model dialog depending on their auth method, or who encounter unexpected behavior when switching between auth methods. Documenting this restriction would improve transparency and help with troubleshooting.
URL of the page with the issue
https://geminicli.com/docs/get-started/authentication/
Additional relevant pages:
What is the problem?
The documentation does not mention that the
gemini-3.1-pro-preview-customtoolsmodel variant is only available when authenticating via Gemini API Key (i.e., an API key created from Google AI Studio, corresponding toAuthType.USE_GEMINIin the codebase).This auth-based model restriction is enforced across the entire codebase — in model resolution (
resolveModel), model routing (classifier and numerical classifier strategies), policy chains, the/modeldialog UI, and the ACP client — via auseCustomToolModelflag that evaluates totrueonly whenuseGemini3_1 === true && authType === AuthType.USE_GEMINI.Key code evidence:
packages/core/src/config/config.ts—getUseCustomToolModel()andgetUseCustomToolModelSync()both gate onAuthType.USE_GEMINIpackages/core/src/config/models.ts—resolveModel()conditionally returnscustomtoolsvariant only when the flag is setpackages/cli/src/ui/components/ModelDialog.tsx— UI only showscustomtoolsmodel for API Key userspackages/cli/src/acp/acpClient.ts—buildAvailableModels()applies same restrictionPartially related issues and PRs:
customtoolsmodel resolution for API key users (closed, not merged)customtoolsfallback chain behaviorWhat did you expect to happen?
I expected the documentation to clearly state that authentication method affects which models are available. Specifically:
docs/get-started/authentication.md): The auth methods comparison table should note model availability differences — e.g., thatgemini-3.1-pro-preview-customtoolsis exclusive to Gemini API Key auth (AI Studio keys).docs/cli/model.md): Should mention thecustomtoolsvariant and its auth requirement, since users choosing models via/modelor--modelmay see different options depending on their auth method.docs/get-started/gemini-3.md): Already mentionsgemini-3.1-pro-previewbut does not mention thecustomtoolsvariant or that it's auth-gated.docs/cli/model-routing.md): Routing behavior (policy chains, classifier strategies) differs by auth type, but this is not documented.Additional context
From code analysis, what can be confirmed is:
gemini-3.1-pro-preview-customtools✅gemini-3.1-pro-preview(thecustomtoolssuffix is not applied)This discoverability gap could cause confusion for users who see different models listed in the
/modeldialog depending on their auth method, or who encounter unexpected behavior when switching between auth methods. Documenting this restriction would improve transparency and help with troubleshooting.