# Claude Code — OpenGen Setup

> Register an HTTP MCP server, then use the client’s browser authorization.

- **Client kind:** Local agent
- **Integration approach:** Remote HTTP MCP or OpenGen CLI
- **Verification status:** LIVE OAUTH CONNECTED
- **Reviewed:** 2026-11-30
- **Canonical HTML:** https://opengen.dev/docs/clients/claude-code
- **Source reference:** [Claude Code MCP documentation](https://code.claude.com/docs/en/mcp)

## Agent Prompt

```text
Walk the user through connecting Claude Code to OpenGen (https://opengen.dev/mcp for authenticated read+generate OAuth, https://opengen.dev/mcp/readonly for zero-auth catalog discovery, or @opengen-dev/cli for shell workflows) following https://opengen.dev/docs/clients/claude-code.md. Review configuration commands before running them, keep credentials out of prompts and version control, and verify read-only access (balance / find_models / opengen doctor) before proposing any paid generation.
```

## Setup Steps

1. Review the HTTP registration command below before running it. It changes Claude Code’s MCP configuration.
2. Run claude mcp login opengen (or open /mcp inside Claude Code), choose OpenGen and complete browser sign-in and workspace consent.
3. Check connection status with claude mcp get opengen and ask for catalog discovery before requesting a generation.

## Configuration & Commands

### Client configuration command · review before running

```bash
claude mcp add --transport http opengen https://opengen.dev/mcp
```

## Verification Evidence & Cautions

**Recorded evidence (2026-11-30):** Claude Code 2.1.301 (2026-11-30, 484d99f; logout verified 2026-11-28): verified live OAuth DCR + S256 PKCE browser login and Connected MCP status check (claude mcp get, clean POST /mcp handshake) against https://opengen.dev/mcp. Local LLM turn was blocked by Claude Code’s own Anthropic auth (not OpenGen); LLM tool turn execution, token refresh, and billable generation remain pending.

**Important boundaries:** OpenGen accepts registered localhost callbacks with explicit ports, as documented by Claude Code. The complete callback URI must match registration. Claude Code 2.1.301 completed live OAuth DCR + S256 PKCE browser login and a Connected MCP status check (claude mcp get, clean POST /mcp handshake) against https://opengen.dev/mcp (484d99f) on 2026-11-30 (logout also verified 2026-11-28); local LLM turns were blocked by Claude Code’s own Anthropic auth (not OpenGen). LLM tool turn execution, token refresh, and billable generation remain pending.

## Related Links

- [All Agent Clients & Support Matrix](https://opengen.dev/docs/clients.md)
- [MCP Integration Guide](https://opengen.dev/docs/mcp.md)
- [Quickstart Guide](https://opengen.dev/docs/quickstart.md)
- [Installable Skill (skill.md)](https://opengen.dev/skill.md)
- [AI Index (llms.txt)](https://opengen.dev/llms.txt)
