[Feature Request] Add 'claude model list' CLI command for non-interactive model queries
Open 💬 16 comments Opened Nov 28, 2025 by ThePlenkov
Problem
Currently, there is no way to programmatically query available Claude models from the CLI without starting an interactive session and using /model.
Current Workarounds
- Interactive only: Start
claudesession → type/model→ consumes tokens for LLM processing - No CLI command:
claude model listdoesn't exist - API directly: Must use
curlwith API keys manually
Requested Feature
Add a claude model subcommand for non-interactive model queries:
# List all available models
claude model list
# Output:
# ID NAME TYPE CONTEXT
# claude-sonnet-4-5-20250929 Sonnet 4.5 Latest 200K
# claude-3-5-sonnet-20241022 Sonnet 3.5 Standard 200K
# claude-3-opus-20240229 Opus 3 Premium 200K
# claude-3-5-haiku-20241022 Haiku 3.5 Fast 200K
# Show current model for session
claude model current
# Show model info
claude model info claude-sonnet-4-5-20250929
Use Cases
- Scripting/Automation - Check available models before running tasks
- Cost Optimization - Programmatically select cheapest model for task
- CI/CD Pipelines - Validate model availability before running agents
- Documentation - Generate up-to-date model lists
- Debugging - Verify which models are accessible with current API key
Comparison with Similar Tools
GitHub CLI:
gh api /repos/:owner/:repo # Direct API access
gh repo view # Formatted output
Docker CLI:
docker images # List available images
docker inspect <image> # Show image details
Claude Code (requested):
claude model list # List available models (no LLM inference)
claude model current # Show current session model
Benefits
- ✅ Zero token cost (no LLM inference needed)
- ✅ Scriptable (parseable output for automation)
- ✅ Fast (no interactive session startup)
- ✅ Consistent with modern CLI patterns
- ✅ Better DX for power users
Implementation Notes
- Should work without starting interactive session
- Output should be parseable (consider
--jsonflag) - Cache model list locally (refresh periodically)
- Respect API provider (Anthropic, Bedrock, Vertex)
Related Issues
- #10169 - Custom Bedrock models not discoverable in
/modelcommand list - #10717 -
/modelreturns old version of models
---
Environment:
- Platform: Linux (WSL2)
- Version: Claude Code v2.0.x
- Use case: Automation scripts, CI/CD integration
16 Comments
This issue has been inactive for 30 days. If the issue is still occurring, please comment to let us know. Otherwise, this issue will be automatically closed in 30 days for housekeeping purposes.
bump
+1, this would be nice to have. We have custom models setup on Bedrock and choosing models when switching between a claude subscription and Bedrock use is a pain.
I'd definitely also like this feature
That woud be usefull please give it some attention.
I think this feature will make Claude Code more user-friendly.
bump
+1 anything that has versions should be listable
+10000000000 This would be super useful to be able to configure some inhouse tools to use the correct models programatically
Please add this in - there's exactly no possible way to find this out right now - not even what claude.ai tells us to do even...
$ curl https://api.anthropic.com/v1/models \
{"type":"error","error":{"type":"authentication_error","message":"OAuth authentication is currently not supported."},"request_id":"req_011Cad8bMLnLV5K51nXzeLJ8"}
you can see the existing models via running
claude, then/modelThe idea of the ticket is to not use then interactive one and have a programmatic way of doing it.
Still not a thing. Codex already have this.
yaa, that woud be usefull please give it some attention
Would definitely need this. It could even return a simple list. Similarly as what opencode does when calling "opencode models":
❯ opencode models
opencode/big-pickle
opencode/deepseek-v4-flash-free
opencode/hy3-free
opencode/mimo-v2.5-free
opencode/nemotron-3-ultra-free
opencode/north-mini-code-free
omlx/gemma-4-12B-it-8bit
You can still install ant with 'brew install anthropics/tap/ant' if you are on macos. For me being doing it through the installed claude CLI, and returning a simple model list name/id would be the best though...
<img width="2110" height="287" alt="Image" src="https://github.com/user-attachments/assets/9f292f25-3a4c-4928-ba7e-37a5f1c165ac" />