# Anthropic --- The Anthropic provider authenticates the **Claude Code and opencode agents** with an Anthropic API key from your own Anthropic account. Usage is billed by Anthropic directly. If you're new to configuring providers, start with the [LLM Providers](/docs/ai-providers/llm-providers/) overview — it covers where the settings live, how keys are stored, and how rotation works for every provider. ## Adding an Anthropic key 1. Create a key at platform.claude.com/settings/keys. Copy it — Anthropic only shows it once. 2. In the dashboard, go to **Organization Settings → Agents → LLM Providers**. 3. On the **Anthropic Direct** card, paste the key into the **API key** field. It starts with `sk-ant-api03-`. 4. Optionally click the eye icon to unmask the field and confirm you pasted the whole key. 5. Click **Save**. You'll get an "Anthropic Direct saved" confirmation, and the field collapses to a masked display. ## Rotating Click **Replace** next to the masked key, paste the new one, and save. The existing key stays active until the new one is saved — see [Rotating a key](/docs/ai-providers/llm-providers/#rotating-a-key). **Remove** deletes the credential entirely. ## Troubleshooting - **"API key looks too short"** — you probably copied a partial value. Anthropic console keys are around 100 characters. Re-copy the whole key. - **A Task fails with an authentication error** — the saved key may have been revoked or may have hit a spend limit. Check the key's status in the Anthropic console, then rotate it using **Replace**. - **Runs fail after switching agents** — the Anthropic key serves the Claude Code and opencode agents. If you've switched to the Codex agent, configure [OpenAI](/docs/ai-providers/openai/) as well; agents never fall back to another provider's key. --- Source: https://deployment.io/docs/ai-providers/anthropic/