Claude Code
This guide explains how to configure Claude Code to work with Claude models available through AIML API.
Overview
Claude Code is a powerful coding agent by Anthropic that can analyze codebases, generate code, and assist with development workflows. By pointing it to AIML API, you can use Claude models available on our platform without connecting directly to Anthropic.
Prerequisites
Node.js 18+
npm
Step 3 — Select a Model
Claude Code requires a model name. Use any Claude model available on AIML API:
export ANTHROPIC_MODEL=claude-haiku-4-5Usage Examples
Ask about your codebase
claude "Explain the architecture of this project"Refactor code
Generate new functionality
How It Works
Claude Code communicates using the Anthropic API format. AIML API provides a compatible interface, so no changes to request structure are required.
All requests are routed through:
Notes
Only Claude models available on AIML API can be used
Performance and pricing depend on the selected model
No additional SDK setup is required
Using CLAUDE.md files
CLAUDE.md is a markdown file placed in your project root that Claude Code automatically reads at the beginning of each session. It can be used to define coding conventions, architectural guidelines, preferred libraries, workflows, and review requirements.
Usage & Cost Monitoring
If you need to monitor usage and costs separately, you can create a dedicated API key for Claude Code usage in your Account. After that, you can view token usage details and corresponding USD costs in the dashboard under the Usage section.
For details, see the API keys and Usage sections in the Starter Guide.
Troubleshooting
Summary
By configuring Claude Code to use AIML API, you can:
Run Claude models via a unified API
Integrate coding agents into your workflow
Avoid direct dependency on Anthropic infrastructure
Last updated
Was this helpful?