Anthropic with DevFlow: setup, scope and limits

An Anthropic key lets DevFlow's OpenCode agents call Claude models on your own account instead of through OpenRouter. Every run whose model ID starts with anthropic/ uses it. Setup is 5 steps in Workspace Settings → Billing → Model access.

Kind
Model provider
Where to set it up
Workspace Settings → Billing → Model access
Plan
All plans
Agent roles
Any OpenCode role set to an anthropic/ model
Verified
1 Oct 2026

Setup steps

  1. Create an API key. In your Anthropic console, create a key dedicated to DevFlow.
  2. Open the Billing tab. As an owner, open the Billing tab and find "Model access"; click "Manage keys" if the provider cards are folded away.
  3. Add the key under Add provider. First-party cards stay hidden until a key exists, so use "Add provider" at the bottom: type ANTHROPIC_API_KEY as the name, paste the secret into "API key" and click "Add".
  4. Test the key. On the card that now appears, click "Test". DevFlow lists models at https://api.anthropic.com/v1/models, sending the key in the x-api-key header, and reports the answer. A key typed into the field but not yet saved is tested in place of the stored one, so a replacement can be checked before it goes live.
  5. Choose Claude models. In the Execution tab, set "OpenCode Model", a tier or a single role to an ID such as anthropic/claude-sonnet-4-6.

What it does

DevFlow has two agent backends. OpenCode, the default, reads the stored key; the Claude Code CLI backend stays off unless the operator sets CLAUDE_BACKEND_ENABLED, and even then it signs in with the server's own CLI session rather than a per-workspace key.

While that second backend is off, a run configured for it is moved to OpenCode with the workspace default, so a leftover setting can never start a run with nothing to call. The settings page also hides the Claude Code option.

IDs take the form provider/model, for example anthropic/claude-sonnet-4-6. One ID can be the default OpenCode Model, back a whole tier, or be pinned to a single role or to one task.

Planning and verification always request the highest reasoning effort. Rate-limit, overload and unavailable answers (429, 529 and 503) are retried with exponential backoff up to 4 attempts in all, while any other failure ends the run.

Anthropic is one of two providers, with OpenAI, that the optional context-compression proxy can front. Requests then pass through a proxy such as Headroom before reaching Anthropic; lossy compression rewrites the start of each request, which can turn prompt-cache hits into misses, so compare total spend per task before keeping it.

When an operator enables it, the Claude Code backend uses the Landlock sandbox path and is never containerized, while OpenCode runs can use a per-invocation container instead.

A single run may last up to 90 minutes and is stopped after 45 minutes without output, whatever the provider. Only the operator can change either limit, through AGENT_TIMEOUT_MINUTES and AGENT_IDLE_TIMEOUT_MINUTES.

Requirements

Limits

FAQ

Can a DevFlow workspace use an Anthropic key and an OpenRouter key together?

Yes. The prefix of each model ID decides which stored key a DevFlow run uses, so different roles can run on different providers inside one task.

Does storing an Anthropic key make DevFlow switch to Claude models?

No. Storing the key only makes Claude IDs usable; the workspace default, the tiers and any per-role or per-task override still decide what each DevFlow run calls.

Sources

Every fact above comes from these files in the DevFlow repository.