Optio supports two AI agent backends: Claude Code (Anthropic) and OpenAI Codex. You select the agent when creating a task or set a default per-repository. Each backend has its own authentication and configuration options.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/jonwiggins/optio/llms.txt
Use this file to discover all available pages before exploring further.
- Claude Code
- OpenAI Codex
Claude Code
Claude Code is the default agent in Optio. It supports three authentication modes.Authentication modes
API key (pay-per-use)
API key (pay-per-use)
The simplest mode. Requests are billed directly to your Anthropic account.
- Get an API key from console.anthropic.com.
- In Optio, go to Settings → Secrets and add a secret named
ANTHROPIC_API_KEYwith your key as the value. - Add a secret named
CLAUDE_AUTH_MODEwith the valueapi-key.
ANTHROPIC_API_KEY as an environment variable into each agent pod.OAuth token (recommended for Kubernetes)
OAuth token (recommended for Kubernetes)
Uses your Claude Max or Pro subscription instead of API billing. The token is extracted from your local macOS Keychain once and stored encrypted in Optio’s secrets store, where it is injected into agent pods.
- On a Mac where you are signed in to Claude, run the one-liner shown in the Optio setup wizard to extract your OAuth token.
- Paste the token into Settings → Secrets as a secret named
CLAUDE_CODE_OAUTH_TOKEN. - Add a secret named
CLAUDE_AUTH_MODEwith the valueoauth-token.
Max subscription (local dev only)
Max subscription (local dev only)
Optio reads credentials directly from the host machine’s macOS Keychain or
~/.claude/.credentials.json. This only works when the Optio API server runs on your local machine — it does not work in Kubernetes.Set CLAUDE_AUTH_MODE to max-subscription. No API key secret is required.Model and performance settings
These settings are configured per-repository in Repos → [repo] → Settings.| Setting | Description | Default |
|---|---|---|
| Model | Which Claude model to use (e.g., claude-sonnet-4-5, claude-opus-4-5). Enter the model ID as shown in the Anthropic documentation. | — |
| Context window | Context window size in tokens. Leave blank to use the model default. | — |
| Extended thinking | Enables Claude’s extended thinking mode for harder problems. | Disabled |
| Effort level | Thinking effort: low, medium, or high. Only relevant when extended thinking is enabled. | — |
| Max turns (coding) | Maximum agent conversation turns per coding task. Leave blank to use the global default. Lower values reduce cost. | null (global default) |
| Max turns (review) | Maximum turns for review subtasks. Leave blank to use the global default. | null (global default) |
Prompt templates
The system prompt sent to the agent is rendered from a template. You can customize the global default or set a per-repository override.Where prompts are configured
- Global default: Settings → Prompt templates — applies to all repositories that do not have an override.
- Per-repository override: Repos → [repo] → Settings → Prompt template — takes precedence over the global default for that repository.
Template variables
The following variables are replaced when the template is rendered:| Variable | Value |
|---|---|
{{TASK_FILE}} | Path to .optio/task.md inside the worktree — the file containing the full task description |
{{BRANCH_NAME}} | The git branch the agent is working on (e.g. optio/task-abc123) |
{{TASK_ID}} | The Optio task UUID |
{{TASK_TITLE}} | The task title |
{{REPO_NAME}} | The repository full name (e.g. acme/backend) |
{{AUTO_MERGE}} | true if auto-merge is enabled for the repository, otherwise false |
Conditional blocks
You can show or hide sections of the prompt based on a variable’s value:false, and not 0.
The task file
The task title and description are written to.optio/task.md inside the agent’s git worktree before the agent starts. The default prompt template instructs the agent to read this file first. This keeps the prompt short while allowing arbitrarily long task descriptions.
