Anthropic Integration
Connect Anthropic to give Claude Code agents an API key when they run on a cloud computer. Every cloud run that uses Claude Code is billed to this connection's Claude Console account. On your laptop, Claude Code uses your own sign-in instead; Autoheal never stores a Claude sign-in.
What it is used for
| Use | Description |
|---|---|
| Claude Code agents | An agent with a claude: section runs Claude Code on a cloud computer with this key |
| Coding agent checks | Project settings → Coding agents → Check runs Claude Code once to confirm the key works |
The connection belongs to a project. A Claude Code run uses the connection of the project it runs in.
Prerequisites
- Computers turned on for your organization
- A Claude Console API key
- For an organization-wide key, the ID of the workspace to bill
Setup
- Create an API key
- Sign in to the Claude Console
- Go to API keys and click Create key
- Create it in the workspace you want to bill, and copy the key (
sk-ant-...)
- Add Integration in Autoheal
- Go to Integrations in the project whose agents use Claude Code
- Click Anthropic
- Enter a name (e.g., "Claude Code billing")
- Configure Credentials
Enter the following:
- API Key: your Claude Console API key
- Workspace ID (optional): only for an organization-wide key, the workspace to bill (
wrkspc_...). Leave it empty for a workspace key.
- Save and check
Save the integration, then open Project settings → Coding agents, select Claude Code and click Check.
Use it in an agent
Add a claude: section to the agent's agent.yaml:
YAML
model: anthropic:claude-sonnet-5
claude:
mode: acceptEdits
version: "2.1"
modeis the session's permission mode:acceptEditsedits files without asking;defaultasks first;planchanges nothing. Left out, the adapter's default applies.versionpins the coding agent's version, as a prefix. Leave it out to run the version installed on the computer: a pinned version is refused once the computer image moves past it.integrationnames the Anthropic connection whose key it uses. Only needed when the project has several.
A project admin can turn Claude Code off in Project settings → Coding agents; its runs are then refused.