Skip to main content
The codegen CLI is your terminal interface to Codegen agents. Use it to view agents, pull their work, create new agents, and run Claude Code with full telemetry and monitoring.
It also wraps your local Claude Code, surfaces traces in the web UI for remote telemetry and analytics, and provides access to your Codegen integrations via MCP injection.

Installation & Setup

uv tool install codegen
The CLI uses your API token for authentication. Get your token and organization ID from the authentication guide.
codegen login

Key Commands

codegen

Launches the interactive terminal UI (TUI) for browsing agents, viewing runs, and managing your Codegen workflow from the terminal.

codegen login

Store your API token for authentication. Supports both interactive login and direct token input.
# Interactive login
codegen login

# Direct token login
codegen login --token YOUR_API_TOKEN

codegen update

Keep your CLI up to date with the latest features and improvements. The CLI automatically checks for updates daily and notifies you when new versions are available.
# Update to latest version
codegen update

# Check for updates without installing
codegen update --check

# Update to a specific version
codegen update --version 1.2.3

# Preview changes without updating
codegen update --dry-run

What You Can Do

  • View and manage agents - List agent runs, check status, and see detailed execution logs
  • Pull agent work - Download branches and code changes created by agents directly to your local environment
  • Create new agents - Trigger agent runs from the command line with custom prompts
  • Run Claude Code - Execute Claude Code with OpenTelemetry monitoring and comprehensive logging
  • Manage organizations - Switch between organizations and configure repositories
  • Stay up to date - Built-in self-update system with automatic update notifications
The CLI provides the same capabilities as the web UI and API, optimized for terminal-based workflows and automation.

Full Demo

Get Started