Use your existing Codex Pay balance
No separate Claude subscription or Anthropic sign-in is needed. Copy your Base URL and Pay API Key from Dashboard β Claude Code.
PhotonMark Codex
Claude Code & Desktop
Use your active Codex Pay balance with Anthropic's official Claude Code CLI, the Claude desktop app (Code mode only), and VS Code, Cursor, or JetBrains plugins. No Anthropic account sign-in is required.
No separate Claude subscription or Anthropic sign-in is needed. Copy your Base URL and Pay API Key from Dashboard β Claude Code.
Most users prefer the Claude desktop app (no terminal needed). Developers in terminals or servers can use Claude Code CLI or editor plugins.
In Claude Desktop, enable Developer mode on the Sign In screen, enter the Gateway URL & key, relaunch, and work inside the Code tab.
Supported clients: PhotonMark Claude routes accept only the official Claude Code clients (CLI, VS Code / Cursor, JetBrains, and Claude Desktop's Code mode). Ordinary Claude Desktop chat, third-party API aggregators/relay panels, and non-official clients or scripts are refused with HTTP 403/405. If a route is slow or unavailable, check the status page and switch to another available route.
Graphical app for macOS, Windows, and Linux (beta). Uses the built-in Developer gateway settings rather than CLI settings.json.
For terminals and servers on macOS, Linux, WSL, and Windows. Configured once in ~/.claude/settings.json.
Works inside your editor and shares ~/.claude/settings.json with the CLI.
Already use CC Switch? Import PhotonMark from the Dashboard in one click instead of editing settings.json.
claude-fable-5-2 locally.| Route | Base URL | Notes |
|---|---|---|
| Mixed (recommended Β· default) | https://codex.photonmark.com/anthropic-mixed |
Opus 5.5, Sonnet 5.5, and Haiku 5.5 run on our self-managed line (prompt non-storage commitment); Fable 5.2 routes through a third-party supplier for lower cost (Fable on Mixed does not carry the self-managed prompt-non-storage commitment). |
| Self-managed (all-model privacy) | https://codex.photonmark.com/anthropic |
All models including Fable 5.2 run on the self-managed line. Legacy /anthropic3 still points here temporarily for about one month. |
| Route 2 (third-party backup) | https://codex.photonmark.com/anthropic2 |
Third-party supplier backup channel. Check the status page before switching. |
| Route 1 (third-party) | https://codex.photonmark.com/anthropic1 |
Third-party channel (availability shown on the status page; no Haiku 5.5). |
Exact per-model prices are on the pricing page, and live route availability is on the status page. Effort is capped across all routes (Fable: Medium; Opus and Sonnet: High), and fast mode (/fast) is not available.
Important: The Claude desktop app does not read the CLI's ~/.claude/settings.json, and ordinary Desktop Chat is not supported. After saving the gateway settings below, make sure you switch to the Code tab (local coding session) rather than sending messages in the Chat tab, or the proxy will return HTTP 403.
Download and install the latest macOS, Windows, or Linux (beta) build from Downloads β Claude desktop app. Launch the app and leave it on the initial Sign In screen β do not sign up or sign in with Anthropic.
On the initial Sign In screen (no Anthropic sign-in needed), open the menu button (β° in the top left on Windows/Linux, or the top menu bar on macOS) and go to Help β Troubleshooting β Enable Developer Mode.... Confirm the prompt so the app restarts; after restart, a new Developer menu appears.

Open Developer β Configure third-party inference, then fill in these fields under Connection:
https://codex.photonmark.com/anthropic-mixed (or https://codex.photonmark.com/anthropic for the all-model self-managed line). Do not append /v1 or a trailing slash.You can click Test connection in the top right (our proxy answers Desktop's built-in gateway probe automatically), then save the settings for this computer and relaunch Claude Desktop.
/anthropic shown here; you can also use /anthropic-mixed or another open route, and enter your own Pay API Key).
After relaunch, click the Code tab (not Chat), open a local project folder, select a supported model (such as Sonnet 5.5, Opus 5.5, or Fable 5.2), and send a short test prompt.
{
"inferenceGatewayBaseUrl": "https://codex.photonmark.com/anthropic-mixed",
"inferenceGatewayApiKey": "your Pay API Key",
"modelDiscoveryEnabled": true,
"inferenceProvider": "gateway",
"inferenceCredentialKind": "static"
}
Switching routes or returning to an official Anthropic login: Reopen Developer β Configure third-party inference at any time to change the Gateway base URL (for example to /anthropic or /anthropic2) or switch back to official Claude sign-in. Official Anthropic history and gateway sessions are kept separately.
Use the official installer from Downloads β Claude Code CLI (recommended because it updates itself automatically):
curl -fsSL https://claude.ai/install.sh | bashirm https://claude.ai/install.ps1 | iexOpen a new terminal and run claude --version to verify the install. On Windows, installing Git for Windows is recommended so Claude Code can run its Bash tool.
~/.claude/settings.jsonCreate or edit the user-level settings file at ~/.claude/settings.json (Windows: C:\Users\your-username\.claude\settings.json; create the .claude folder if it does not exist yet). If the file already has an env block, merge the entries below into it, or copy the pre-filled block with your Pay API Key from Dashboard β Claude Code:
{
"env": {
"ANTHROPIC_BASE_URL": "https://codex.photonmark.com/anthropic-mixed",
"ANTHROPIC_AUTH_TOKEN": "your Pay API Key",
"CLAUDE_CODE_AUTO_COMPACT_WINDOW": "400000"
}
}
Keep your Pay API Key out of shared repositories or public files. CLAUDE_CODE_AUTO_COMPACT_WINDOW is optional and recommended so long sessions compact near 400,000 tokens.
Open a new terminal inside your project folder, run claude, and send a short test prompt. Usage appears under Dashboard β Usage & billing.
CC Switch is a third-party open-source app that writes the Claude Code settings for you and lets you switch between providers. It configures the same ~/.claude/settings.json as step 2, so it covers the CLI and the editor plugins; for the Claude desktop app use the built-in gateway setting in step 1.
.msi installer from the latest release.brew install --cask cc-switch, or the .dmg from the same release page..deb, .rpm or .AppImage from the same release page.Claude Code itself must be installed first (step 2, "Install the CLI").
Open Dashboard β Claude Code, pick a route, and click Import into CC Switch (Claude Code). Your browser asks to open CC Switch; check that the request URL is the route you picked, then click Import. The link is built in your browser with your Pay API Key and is not sent anywhere else.
Prefer to type it in? In CC Switch choose Claude Code, add a custom provider, enter the route URL from the Dashboard (for example https://codex.photonmark.com/anthropic-mixed) as the request URL and your Pay API Key as the API key. Do not pick another site's preset.
Click the switch button on the PhotonMark card so it shows as in use, restart Claude Code (or reload the editor window), and send a short test prompt.
Keep CC Switch in direct mode. Do not turn on its routing / local proxy mode for PhotonMark: our Claude routes accept only requests sent unchanged by the official Claude Code client, and requests relayed by a local proxy may be refused.
Codex Pay can be imported the same way from the Pay card in the Dashboard; see the CC Switch FAQ for Codex.
Complete CLI configuration (~/.claude/settings.json) first; editor plugins read the same configuration.
Install the official Claude Code extension from the Downloads page (requires VS Code 1.94+; in Cursor, search for Claude Code in Extensions). The extension reads ~/.claude/settings.json. If it still displays an Anthropic sign-in screen, turn on Disable Login Prompt in the Claude Code extension settings and reload the window.
For IntelliJ IDEA, PyCharm, WebStorm, GoLand, Android Studio, and other JetBrains IDEs. The plugin invokes the local claude command, so install and configure the Claude Code CLI first, install the plugin from the Downloads page, and restart the IDE.
/compact before then, or /clear to start a new session.env in the command-line ~/.claude/settings.json (Windows: C:\Users\your-username\.claude\settings.json). Claude Code then compacts automatically as the context nears 400,000 tokens, which helps control the cost of long sessions:
"CLAUDE_CODE_AUTO_COMPACT_WINDOW": "400000"
| Symptom / error | What to check |
|---|---|
HTTP 403 client_not_allowed |
You are either sending a message in Claude Desktop's ordinary Chat tab instead of the Code tab, or calling the route from an unsupported third-party client, curl, or Agent SDK script. Switch to Desktop's Code workspace or the official Claude Code CLI / IDE plugin. |
HTTP 403 with Claude Code auto mode |
Claude Code auto mode's classifier requests are not supported on Claude routes. Turn off auto mode and confirm actions normally. |
HTTP 402 / insufficient balance |
Check your Codex Pay balance in Dashboard. Requests require more than the $0.10 balance buffer plus active in-flight reserves; top up Pay and retry. |
unrecognized_model for claude-fable-5-2 |
Your Claude Code client is out of date (CLI versions before 2.1.321 reject Fable 5.2 locally). Upgrade Claude Code or Claude Desktop to the latest release. |
HTTP 429 too many active Claude sessions |
On the self-managed line each API key can have a limited number of Claude sessions active at once (4 by default) and a limited number of different sessions within 15 minutes (6 by default). A session stays active until about 3 minutes after its last request; every new window, /clear, or claude -p run starts another one, while subagents share the session they belong to. Continue in a session you used recently, or wait a few minutes before starting a new one. Refused requests are not charged. |
Slow responses, 502, 503, or 429 |
Check the status page and switch your Base URL to another open route (for example between /anthropic-mixed, /anthropic, and /anthropic2). Avoid high-frequency parallel multi-agent bursts on the self-managed line. |
| Safety filter keeps blocking the same conversation | In Claude Code, press Esc twice (or run /rewind) and restore the conversation only to before the blocked message, or run /clear to start fresh. See FAQ: safety filter. |
Official Anthropic documentation: Claude Code setup, Connect Desktop app to an LLM gateway, and Claude Desktop third-party inference configuration.