The complete reference
This page gets you installed and shipping a first fix. The full documentation covers the CLI, review, the MCP server, the GitHub App, the GitHub Action, configuration and core concepts at docs.codna.ai.
Python 3.10 or newer, macOS or Linux, and git. No Node, Docker or server to install.
This page gets you installed and shipping a first fix. The full documentation covers the CLI, review, the MCP server, the GitHub App, the GitHub Action, configuration and core concepts at docs.codna.ai.
Install the CLI from PyPI with pip, pipx or uv. Everything runs on your machine. Sign in for the managed allowance, or store your own provider key in the OS keychain.
pip install codna codna --version codna key set anthropic
First, understand a repo for zero tokens. Then ask Codna to fix a specific issue.
codna triage . codna fix . --issue "the checkout test is failing"
Triage, fix, review and secure. Every command takes --json, and errors arrive as JSON on stderr.
codna triage . --json codna fix . --tests --apply --max-iterations 3 codna fix https://github.com/org/repo --issue "..." --open-pr codna review . --pr 42 --post codna secure . --from-sarif results.sarif
Install the mcp extra, then add Codna to Cursor or Claude in one command. Five tools: codna_triage, codna_fix, codna_secure, codna_recall and codna_report_bug.
pip install "codna[mcp]" codna mcp install --client cursor codna mcp install --client claude
Install the App on your account or organization and pick the repositories. Codna reviews every pull request. Link the install to a Codna account for managed fixes, or add your own key.
# On a pull request @codna review # Reply on a Codna finding (write access) @codna fix # On an issue label: codna-fix · codna-secure
codna.yaml holds the model provider, privacy settings and your test command. Secret redaction is always on.
model: provider: anthropic key: env:ANTHROPIC_API_KEY privacy: egress: fail-closed redact_secrets: true fix: test_command: pytest -q
What leaves my machine? Only the evidence bundle or the diff, sent to your model provider with your key. Triage and recall run offline.
Where do I report a bug? Run codna report. It files to the public feedback repository, and falls back to a pre-filled issue link when you have no token.
pip install codna, pipx install codna, or uv tool install codna. You need Python 3.10 or newer, macOS or Linux, and git on your PATH. The CLI runs locally with your own model key.
Cursor and Claude. Install the mcp extra, then run codna mcp install --client cursor or --client claude. The server never writes credentials into your editor config.
The App runs the same codna commands, hosted by Codna. It reviews every pull request, answers @codna review, opens a fix when a collaborator with write access replies @codna fix on a finding, and acts on the codna-fix and codna-secure labels and on red check suites.
The CLI runs on your machine. Your provider key lives in the OS keychain and is never printed. Only the evidence bundle or the diff reaches your model provider. Set privacy.egress to fail-closed in codna.yaml and Codna runs your tests only under kernel-level network denial and makes no registry lookups during review.
On 87 matched cases against Cursor, Codna averaged 16,159 tokens and about $0.02 of model spend per verified fix, 5× fewer tokens and 1.7× faster.
The repository map is built from import patterns, so it is not tied to one language. On-device recall covers Python, JavaScript, TypeScript, Go, Rust, Java, C, C++, C#, PHP and Ruby. Set fix.test_command to your own test runner.