
# Connect Claude Code

## OAuth browser sign-in

Sign in with your Reconstruct account in the browser. You do not need to create a personal token on the Platform. See [MCP OAuth setup](../connect-ai-agents.md#oauth-browser-sign-in) for the shared connection settings.

```sh
claude mcp add --transport http --client-id reconstruct-mcp --callback-port 8080 reconstruct https://reconstruct.dev/mcp
```

Run `/mcp` and follow the browser sign-in. No client secret is required. The registered callback is `http://localhost:8080/callback`. Remove the manually configured `Authorization` header when choosing OAuth. See [Claude Code OAuth configuration](https://code.claude.com/docs/en/mcp#use-pre-configured-oauth-credentials).

If your installed Claude Code version changes the callback host from `localhost` to `127.0.0.1`, update to a current version or contact support with the exact redirect URI. Do not widen the callback address yourself.

## Personal access token

Copy your MCP access token from your [Reconstruct Platform account settings](https://reconstruct.dev/platform/). See [Personal access token](../connect-ai-agents.md#personal-access-token) for the connection requirements. Set `CR_RECONSTRUCT_MCP_TOKEN` in the environment that launches Claude Code.

Create `.mcp.json` in your project root:

```json
{
  "mcpServers": {
    "reconstruct": {
      "type": "http",
      "url": "https://reconstruct.dev/mcp",
      "headers": {
        "Authorization": "Bearer ${CR_RECONSTRUCT_MCP_TOKEN}"
      }
    }
  }
}
```

Keep this file out of version control if you substitute a literal token. Start Claude Code in that project, approve the server when prompted, and run `/mcp` to check its status. Ask Claude Code to call `list_products` to confirm access. See the [official Claude Code MCP configuration](https://code.claude.com/docs/en/mcp).

Next, try the [prompt examples](../prompt-examples.md).
