About Anthropic Cli
The Anthropic CLI, invoked as ant, is Anthropic's official command line tool for the Claude API. Every API resource is exposed as a subcommand, so developers can send Messages requests, manage resources and connect to Managed Agents sessions directly from a terminal, with formatted output, response filtering and input from YAML or JSON files.
It is aimed at developers and operators who work with Claude from scripts, CI jobs and the shell rather than through an SDK. Compared with calling the API through curl, ant builds request bodies from typed flags or piped YAML instead of hand written JSON, inlines file contents into string fields with an @path reference, extracts response fields with a built in transform query so no separate JSON tool is needed, and paginates list endpoints automatically. The ant auth login command runs a browser based OAuth flow against the Claude Console and stores credentials locally, so no API key has to be created; API key environment variables, headless hosts, multiple workspaces, named profiles and Workload Identity Federation are also supported. The documentation covers scripting and automation and managing resources as code. It installs through Homebrew on macOS, a curl script on Linux and WSL, or Go, and ships shell completion for bash, zsh, fish and PowerShell.
The CLI itself is free. Requests made through it are billed at standard Claude API rates per million tokens: Claude Fable 5.1 at $10 input and $50 output, Claude Opus 5.5 at $4 and $20, Claude Sonnet 5.5 at $2 and $10, and Claude Haiku 4.5 at $1 and $5.
The tool sits alongside Anthropic's client SDKs for Python, TypeScript, C#, Go, Java, PHP and Ruby, and is separate from Claude Code, Anthropic's agentic coding product.