You need your API key (a UUID) and your 6-digit code set at key creation. Log in at the dashboard or pass the key directly to any client.
Pass your key in either header — both are accepted:
x-api-key: YOUR_KEY Authorization: Bearer YOUR_KEY
Base URL for all requests:
https://api.easytokens.net/
npm install -g @anthropic-ai/claude-code
# Clear existing credentials first unset ANTHROPIC_API_KEY ANTHROPIC_AUTH_TOKEN ANTHROPIC_BASE_URL export ANTHROPIC_BASE_URL="https://api.easytokens.net/" export ANTHROPIC_AUTH_TOKEN="your-easytokens-api-key" export ANTHROPIC_DEFAULT_HAIKU_MODEL="claude-haiku-4-5-20251001" export ANTHROPIC_DEFAULT_SONNET_MODEL="claude-sonnet-4-6" export ANTHROPIC_DEFAULT_OPUS_MODEL="claude-opus-4-8"
ANTHROPIC_AUTH_TOKEN and ANTHROPIC_API_KEY are set. Unset ANTHROPIC_API_KEY first./api/. If you see 404s or "model not found", use https://api.easytokens.net/api/.claude
pip install anthropic
import anthropic
client = anthropic.Anthropic(
api_key="your-easytokens-api-key",
base_url="https://api.easytokens.net",
)
msg = client.messages.create(
model="claude-sonnet-4-6",
max_tokens=1024,
messages=[{"role": "user", "content": "Hello"}],
)
print(msg.content)
npm install @anthropic-ai/sdk
import Anthropic from "@anthropic-ai/sdk";
const client = new Anthropic({
apiKey: "your-easytokens-api-key",
baseURL: "https://api.easytokens.net",
});
const msg = await client.messages.create({
model: "claude-sonnet-4-6",
max_tokens: 1024,
messages: [{ role: "user", content: "Hello" }],
});
console.log(msg.content);
easytokens implements the Anthropic Messages API, so any app that lets you pick an Anthropic provider with a custom base URL works out of the box. Set the base URL to https://api.easytokens.net and use your easytokens key as the Anthropic API key. The endpoint is served on /v1/messages, /api/v1/messages and /messages, so it does not matter how the app joins the base URL and path.
| App | Where to configure |
|---|---|
| Cline / Roo Code / Kilo Code | Settings → API Provider: Anthropic → enable Use custom base URL → https://api.easytokens.net, paste your key. |
| OpenCode | In opencode.json set the anthropic provider's baseURL to https://api.easytokens.net and apiKey to your key. |
| Aider | export ANTHROPIC_API_KEY=your-key and export ANTHROPIC_API_BASE=https://api.easytokens.net, then run with an anthropic/… model. |
| Zed | In settings.json: "language_models": {"anthropic": {"api_url": "https://api.easytokens.net"}} and set the Anthropic key in the assistant panel. |
| Continue | Add an anthropic provider block with apiBase: https://api.easytokens.net and your key. |
| LibreChat | In librechat.yaml, point the anthropic endpoint's baseURL at https://api.easytokens.net. |
GET /v1/models is OpenAI-compatible, but there is no /v1/chat/completions endpoint — clients must speak the Anthropic Messages format. If an app only supports OpenAI providers, it will not work yet.Retrieve live via GET /models or GET /v1/models. Base Anthropic per-token prices are listed below.
| Model ID | Name | Input/1M | Output/1M | Context | Features |
|---|---|---|---|---|---|
claude-fable-5 | Claude Fable 5 | $10.00 | $50.00 | 1000K | vision, tools, cache |
claude-opus-4-8 | Claude Opus 4.8 | $5.00 | $25.00 | 1000K | vision, tools, cache |
claude-opus-4-7 | Claude Opus 4.7 | $5.00 | $25.00 | 1000K | vision, tools, cache |
claude-opus-4-6 | Claude Opus 4.6 | $5.00 | $25.00 | 1000K | vision, tools, cache |
claude-opus-4-5-20251101 | Claude Opus 4.5 | $5.00 | $25.00 | 200K | vision, tools, cache |
claude-sonnet-4-6 | Claude Sonnet 4.6 | $3.00 | $15.00 | 1000K | vision, tools, cache |
claude-sonnet-4-5-20250929 | Claude Sonnet 4.5 | $3.00 | $15.00 | 200K | vision, tools, cache |
claude-sonnet-4-5 | Claude Sonnet 4.5 | $3.00 | $15.00 | 200K | vision, tools, cache |
claude-sonnet-4-20250514 | Claude Sonnet 4 | $3.00 | $15.00 | 1000K | vision, tools, cache |
claude-haiku-4-5-20251001 | Claude Haiku 4.5 | $1.00 | $5.00 | 200K | vision, tools, cache |
claude-haiku-4-5 | Claude Haiku 4.5 | $1.00 | $5.00 | 200K | vision, tools, cache |
POST https://api.easytokens.net/v1/messages POST https://api.easytokens.net/api/v1/messages # legacy alias
Request and response format follows the Anthropic Messages API. Non-streaming responses include a _proxy field with cost and token breakdown. count_tokens is available at the same paths.
| Status | Meaning |
|---|---|
| 401 | Missing or invalid API key |
| 402 | Insufficient balance (balance-type keys) |
| 403 | Key inactive, frozen, expired, or model not permitted |
| 429 | Rate cap exceeded — check X-RateLimit-Reset-H4 / X-RateLimit-Reset-H24 |
| 502 | Upstream unreachable |