Overview
This setup allows Claude Code to use models through Znap AI’s Anthropic-compatible endpoint.Prerequisites
Install Claude Code from https://code.claude.com or using npm:Step 1: Configure Claude Code for Znap AI
Open Terminal. Set the following environment variables for the current terminal session:YOUR_ZNAP_API_KEY with your actual API key.
Important: These settings are temporary and only apply to the current PowerShell session. They will automatically be removed when the terminal is closed, allowing you to switch models or API keys without permanently modifying your system.
Step 2: Launch Claude Code
Start Claude Code:gemini-2.5-pro · API Usage Billing in the Claude Code header.

Step 3: Verify the Connection
Run a simple prompt:Changing Models
To use a different model, update the environment variable:
Viewing Available Models
To see the list of available models configured through your gateway, run:
ANTHROPIC_MODEL environment variable.
Example:
Notes
- Claude Code is being configured through an Anthropic-compatible endpoint provided by Znap AI.
- Different models may behave differently depending on the gateway’s compatibility layer.
- At the time of writing,
gemini-2.5-prohas been tested and verified to work successfully with Claude Code. - If you encounter model-specific errors, try switching models and restarting Claude Code.
