Skip to main content
Claude Code is a terminal coding agent. It uses the native Anthropic Messages configuration, so its NexusAPI Base URL is https://nexusapi.link — do not append /v1.

System requirements

  • macOS 13+, Ubuntu 20.04+, Debian 10+, Alpine Linux 3.19+, or Windows 10 version 1809+.
  • At least 4 GB of memory and an x64 or ARM64 CPU.
  • A network that can reach NexusAPI.
  • On Windows, Git for Windows is optional when you prefer Git Bash.

1. Install Claude Code

Use an official installer. A native installation does not require Node.js.

macOS, Linux, or WSL

Windows PowerShell

You may also use WinGet on Windows or Homebrew on macOS:
Verify the installed client before editing configuration:

2. Create a NexusAPI key

In the NexusAPI console, open Token Management → Add token. Give the key a recognizable name, choose a group that contains the model you need for Claude Code, and set an appropriate limit. Do not assume every Claude-branded model is available to every group; verify it in the Model Marketplace or with /v1/models.

Choose safe key settings

Use a project-specific name and a sensible limit. Enable a model restriction or IP allowlist only when you understand the operational impact, and give short-lived test keys an expiry date.

3. Set user-level configuration

Locate the configuration folder

Claude Code reads user settings from: Create it on macOS, Linux, WSL, or Git Bash:
On Windows PowerShell:

Set the environment values

Merge the following env values into an existing file; do not overwrite your MCP, permissions, or other settings.
Keep this in your user directory, not in a project repository. Never commit or screenshot a real key.
Only disable experimental fields when the error asks for itIf an error explicitly mentions unsupported context_management or experimental inputs, add CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1 to env and test again. It disables some preview fields; use it only for this kind of compatibility error.

4. Start and verify

Open a new terminal, enter a project directory, and run:
Run /status inside Claude Code. Confirm that Anthropic base URL is https://nexusapi.link and authentication comes from ANTHROPIC_AUTH_TOKEN, then send a short text message.

Troubleshooting

Invalid API Key · Please run /login

Confirm that both environment values are saved, the key itself is enabled, and the terminal was restarted. Do not solve this by editing Claude’s internal login state files.

Unable to connect to Anthropic services

Run claude doctor, check the JSON syntax in settings.json, then reopen the terminal. If it persists, save the original error, claude --version, and claude doctor output.
Do not use a script to overwrite internal fields in .claude.json. They can change between releases and overwriting the file can remove existing settings.

PowerShell blocks the installer

Use WinGet or the official installer from Windows CMD first. If you have verified that the issue is only your local execution policy, change the policy for the current user only:
Only change the current-user policy after confirming that it is the local cause.

fetch failed

First distinguish a model call from Claude Code’s WebFetch feature.
  1. Send a one-line normal prompt. If it succeeds, NexusAPI model calls are working; troubleshoot WebFetch under its own network and safety rules.
  2. If all model calls fail, run claude doctor and use /status to confirm the Base URL is still https://nexusapi.link.
  3. Check local DNS, firewall, corporate network, or an existing trusted proxy for access to nexusapi.link.
  4. Open a fresh terminal and test once. For persistent failures, retain the version, doctor output, full error, and Request ID, then use the self-check guide.

The status says offline

Some auxiliary features check official or third-party services separately. Verify the actual gateway URL with /status and send a small text request first; offline alone does not necessarily mean an API outage.

WebFetch fails but normal chat works

WebFetch can have separate domain-safety checks and external network access. If a short normal chat request succeeds, the NexusAPI Base URL does not need to be changed; troubleshoot WebFetch under Claude Code’s own network guidance.

An API request fails

Exit the session, start a fresh claude session, and test one short request. If the problem remains, preserve the Request ID and use the self-check guide.

Official references