Claude Code is Anthropic's official terminal-based intelligent coding tool. It allows you to complete code generation, read local files, debug, and refactor directly from the command line using natural language commands.By connecting to DataEyesAI and updating your environment variables, you can replace Claude Code's default official API endpoint with DataEyes, giving you a more stable and cost-effective API service.
Make sure your machine has Node.js (version 18 or higher) installed. Open a terminal (Windows users must use PowerShell). You can check your current environment by running:
Step 2: Upgrade to Native Installation (Critical)#
The official Claude Code team has switched to a Native installation mode. To avoid errors later, run the following command immediately after the base installation completes:
Note: A successful installation will display the message Claude Code successfully installed! in green text.
Windows security policies often block Claude Code from running. If you are on Windows, please complete the following steps before proceeding (Mac/Linux users can skip this section):
If typing claude returns a "command not found" error, the installation directory was not automatically added to your PATH.
Press the Win key and search for "Environment Variables". Add C:\Users\YourUsername\.local\bin to the Path variable under the current user, then restart PowerShell.
Claude Code relies strictly on environment variables to detect a custom proxy. Make sure you set the variables and run the command in the same terminal window.
Option A: Temporary Configuration (Recommended for First-Time Testing)#
Open a terminal (Windows: PowerShell) and paste the following commands line by line, pressing Enter after each:Windows (PowerShell):
$env:ANTHROPIC_AUTH_TOKEN="sk-your-dataeyes-key"$env:ANTHROPIC_BASE_URL="https://platform.dataeyes.ai"
claude
macOS / Linux:
Option B: Permanent Configuration (Recommended for Ongoing Use)#
If you want claude to work every time you open a terminal without re-entering the variables:
Windows: Go to System Environment Variables → User Variables, and create two new variables: ANTHROPIC_AUTH_TOKEN (your key) and ANTHROPIC_BASE_URL (https://platform.dataeyes.ai). Restart your terminal after saving.
Mac/Linux: Add the export statements to your ~/.zshrc or ~/.bashrc file, then run source ~/.zshrc.
Q1: Error: Your credit balance is too low to access the Anthropic API
1.
Your DataEyesAI account may be out of credit: the token quota for the sk-... key you entered may be exhausted. Top up your account to resolve this.
2.
If your DataEyesAI account has sufficient balance, try switching groups or switching models:
Switch groups: Go to the console token page, click Edit, change the token group, and submit.
Switch models: In the Claude Code interface, type:
(Replace gpt-5.4 with any model supported by your console.)Q2: Why does it still show Not logged in / Please run /login?
Check that the variable name is exactly ANTHROPIC_AUTH_TOKEN.
The most common cause: environment variables are session-scoped. You may have set variables in window A but launched Claude in a new window B. Always operate within the same terminal window.
Q3: Should the Base URL include /v1?
No. Under the current DataEyesAI API specification and Claude Code's updated logic, please use exactly https://platform.dataeyes.ai — without /v1.
Q4: What if I accidentally typed /login?
/login is used to log into an official Anthropic account. If you are using DataEyes, do not use this command. If you accidentally entered the login flow, keep pressing Esc to exit — the system will automatically fall back and read your environment variables.