Skip to main content

Unofficial CLI for Devin AI - The first AI Software Engineer

Project description

Devin CLI Logo

Devin CLI (Unofficial) — The Professional Terminal Interface for Devin AI

PyPI version Homebrew Tap Build Status

The first unofficial CLI for the world's first AI Software Engineer. Supports both the modern v3 API and the legacy v1 API with full multi-profile management.

Devin CLI is designed for high-velocity engineering teams. It strips away the friction of the web UI, allowing you to orchestrate autonomous agents, manage complex contexts, and automate multi-step development workflows through a robust, terminal-first interface.


⚡ Quick Start

1. Installation

Recommended: Via Homebrew (macOS)

brew tap revanthpobala/tap
brew install devin-cli

Via pipx (Isolated environment)

pipx install devin-cli

Via pip

pip install devin-cli

2. Configuration

devin configure
# Paste your API token (apk_... or cog_...) from https://preview.devin.ai/settings
# Select API version: v3 (default) or v1 (legacy)

3. Your First Session

devin sessions create "Identify and fix the race condition in our Redis cache layer"

🔑 Multi-Profile Support

The CLI supports multiple named profiles, letting you manage separate tokens, organizations, and API versions from a single install.

# Configure your personal v3 profile
devin configure --profile personal

# Configure a service account profile
devin configure --profile service

# Switch profiles at runtime
devin --profile service sessions list
devin --profile personal sessions create "Fix the failing tests"

Profiles are stored in ~/.config/devin/config.json and are fully isolated — including their session deduplication caches and active session IDs.


🕹 Legacy v1 API Support

If you are running an older integration against the original Devin API v1 endpoints, the CLI acts as a transparent proxy and routes calls to the correct v1 URLs without breaking your v3 integrations.

To configure a v1 profile:

devin configure --profile legacy
# When prompted for API Version, enter: v1
# Set Base URL to: https://api.devin.ai/v1

To use the v1 profile:

devin --profile legacy sessions create "Run the migration script"
devin --profile legacy sessions list

What works in v1:

Feature v1 v3
Sessions (create, list, get, terminate)
Knowledge (create, update, delete)
Playbooks (create, update, delete)
Secrets (list, create, delete)
Attachments (upload, download)
Session Insights
Schedules
Repositories
Enterprise endpoints

The help menu will show (Legacy v1 API) and (v3 Only) tags next to commands when a v1 profile is active.


🛠 Command Reference

Every sub-command supports the --org flag to override your active organization on the fly.

Category Commands Description
Sessions create, list, get, insights, cost, messages, message, terminate Core agent lifecycle and analytics.
Knowledge list, create, delete Manage organizational context and AI memory.
Playbooks list, create, update, delete Automate complex, multi-step agent workflows.
Secrets list, create, delete Pass API keys and credentials to Devin sessions.
Schedules list, create Schedule recurring autonomous tasks via CRON.
Repositories list, index Force indexing of Git repositories for Devin context.
Attachments upload, download Transfer context files seamlessly.
Enterprise whoami, list-orgs Administrative identity discovery.
Global configure, use CLI setup and active session management.

Key Flags

Flag Description
--profile <name> Select a named configuration profile
--org <id> Override the active organization for a single command
--json Output raw JSON (available on sessions list, repos list, secrets list)
--force Skip duplicate session detection and create anyway
--advanced-mode Request an advanced mode session requiring browser auth

🛡 Session Deduplication

The CLI caches a SHA-256 hash of your last 50 prompts per profile. If you attempt to launch a session with an identical prompt, the CLI halts and alerts you before wasting ACUs:

Duplicate Detected: You recently created a session with this exact prompt.
Existing Session ID: abc123...
Are you sure you want to create a duplicate session? [y/N]

Use --force to bypass this check.


📟 CI/CD Integration

# Example GitHub Action Step
env:
  DEVIN_API_TOKEN: ${{ secrets.DEVIN_API_TOKEN }}
  DEVIN_ORG_ID: ${{ secrets.DEVIN_ORG_ID }}
run: |
  devin sessions create "Review PR #${{ github.event.pull_request.number }}"

Supported environment variables:

Variable Description
DEVIN_API_TOKEN Your API token (overrides config file)
DEVIN_ORG_ID Your organization ID
DEVIN_BASE_URL Override the default base URL
DEVIN_API_VERSION Set v1 or v3 without configuring

⚙️ Engineering Specs

  • Architecture: Full v3 API support (including v3beta1 and enterprise endpoints) + v1 legacy proxy
  • Config Storage: ~/.config/devin/config.json
  • Platform Support: Linux, macOS, WSL2
  • Python: 3.9+

🧪 Developer Hub

# Setup
pip install -e ".[dev]"

# Test Suite
PYTHONPATH=src python3 -m pytest

📄 License

MIT. Devin CLI is an unofficial community project and is not affiliated with Cognition AI.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

devin_cli-1.2.0.tar.gz (287.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

devin_cli-1.2.0-py3-none-any.whl (30.4 kB view details)

Uploaded Python 3

File details

Details for the file devin_cli-1.2.0.tar.gz.

File metadata

  • Download URL: devin_cli-1.2.0.tar.gz
  • Upload date:
  • Size: 287.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for devin_cli-1.2.0.tar.gz
Algorithm Hash digest
SHA256 852c5834fe029316a79ba710a349f04252a0a9c25acf57895d4cd322268477f5
MD5 e6a31e0656aa2471437cc03c3f927fc6
BLAKE2b-256 efae3f4c162099ded33ecce8f18d9db23795d6cf3f3e7e2ce583776fb4b43a94

See more details on using hashes here.

Provenance

The following attestation bundles were made for devin_cli-1.2.0.tar.gz:

Publisher: pypi-publish.yml on revanthpobala/devin-cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file devin_cli-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: devin_cli-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 30.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for devin_cli-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 22d5f5c97b8500b989f01f8d1405fc161bbd3831ce3aaf351131e1ad4280340c
MD5 62a480314425240447cabf0936a62fad
BLAKE2b-256 0fbf81d9cc649c7279413ef50b5ff34aa6fc66e3ff0db079bec421b582566036

See more details on using hashes here.

Provenance

The following attestation bundles were made for devin_cli-1.2.0-py3-none-any.whl:

Publisher: pypi-publish.yml on revanthpobala/devin-cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page