> ## Documentation Index
> Fetch the complete documentation index at: https://taskgraph-ai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Authentication

> TaskGraph runs on your signed-in Claude Code. No provider API keys are needed.

TaskGraph runs every AI call through [Claude Code](https://docs.claude.com/en/docs/claude-code). If `claude` works in your terminal, TaskGraph works. There are no provider accounts to create and no API keys to add to `.env` or `.mcp.json`.

## Sign in to Claude Code

```bash theme={null}
claude
```

Run it once and follow the sign-in prompts. TaskGraph then uses that session.

## Optional: `CLAUDE_CODE_API_KEY`

By default TaskGraph withholds `ANTHROPIC_API_KEY` from Claude Code, so Claude Code uses its own sign-in. If you want TaskGraph's AI calls billed to a specific Anthropic API key instead, set `CLAUDE_CODE_API_KEY`. When it is set, it is used exclusively.

```bash Shell theme={null}
export CLAUDE_CODE_API_KEY="sk-ant-api03-your-key-here"
```

```json .mcp.json theme={null}
{
  "mcpServers": {
    "taskgraph-ai": {
      "command": "npx",
      "args": ["-y", "taskgraph-ai"],
      "env": {
        "CLAUDE_CODE_API_KEY": "sk-ant-api03-your-key-here"
      }
    }
  }
}
```

This is the only API key TaskGraph reads, and it is optional.

## Troubleshooting

* **AI commands fail:** run `claude` once and make sure you are signed in. TaskGraph logs a warning if it cannot find the Claude Code CLI; install it with `npm install -g @anthropic-ai/claude-code`.
* **Keys from older versions:** provider API keys left over from earlier releases are ignored. You can remove them.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.