All models, capabilities, and prices

Migrate from Anthropic

If your code already calls api.anthropic.com today, the entire migration is one environment variable. Existing requests and responses are byte-for-byte identical.

What changes (and what does not)

Nothing about the request schema, the response shape, the streaming events, or the SDK you’re already using needs to change. The only diff is where the bytes go:

Reference data
ConcernAnthropicAPI-AI
Base URLhttps://api.anthropic.comhttps://api-ai.app
Auth headerx-api-keyx-api-key or Authorization: Bearer
Version headeranthropic-version: 2023-06-01anthropic-version: 2023-06-01
Request schemaAnthropic Messages APIIdentical
Response schemaAnthropic Messages APIIdentical
Streaming eventsSSE: message_start, content_block_delta...Identical, no buffering
Prompt caching (cache_control)NativeNative — pass-through
Models~15 historical aliasesGenerated Claude allowlist — see Models
BillingCard, post-paid, monthlyPrepaid top-up (card, Apple Pay, crypto), no subscription

Environment-only migration

If your code reads credentials from env vars (it should), this is the whole change:

bash
# Before
export ANTHROPIC_API_KEY=sk-ant-...

# After
export ANTHROPIC_API_KEY=mdf-...               # API-AI key
export ANTHROPIC_BASE_URL=https://api-ai.app

Both the official Anthropic Python and Node SDKs read ANTHROPIC_BASE_URL with no other code changes required.

Python — explicit form

python
# Before
from anthropic import Anthropic
client = Anthropic()

# After
from anthropic import Anthropic
client = Anthropic(
    api_key=os.environ["ANTHROPIC_API_KEY"],
    base_url="https://api-ai.app",
)

Node — explicit form

ts
// Before
import Anthropic from "@anthropic-ai/sdk";
const client = new Anthropic();

// After
import Anthropic from "@anthropic-ai/sdk";
const client = new Anthropic({
  apiKey:  process.env.ANTHROPIC_API_KEY,
  baseURL: "https://api-ai.app",
});

Model id swap

The Anthropic-native surface exposes 16 current Claude ids. If your code references an older Anthropic alias (claude-3-5-sonnet, claude-3-opus-20240229, etc.) you’ll get a 400 invalid_request_error — replace it with the current canonical id:

Reference data
Old aliasUse instead
claude-3-5-sonnet*, claude-sonnet-3-5claude-sonnet-5-5
claude-3-opus*, claude-opus-3claude-opus-4-8
claude-3-haiku*, claude-haiku-3-5claude-haiku-4-5

Verify the swap

bash
# Should print the current Claude model ids
curl -s https://api-ai.app/v1/models \
  -H "x-api-key: $ANTHROPIC_API_KEY" | jq '.data[].id'

# Should return HTTP 200 and a short text message
curl -s https://api-ai.app/v1/messages \
  -H "x-api-key: $ANTHROPIC_API_KEY" \
  -H "anthropic-version: 2023-06-01" \
  -H "content-type: application/json" \
  -d '{"model":"claude-haiku-4-5","max_tokens":32,"messages":[{"role":"user","content":"hi"}]}'
Run both side-by-side first
For paranoid migrations: keep your Anthropic client around for one deploy. Send 1% of traffic through API-AI, diff the responses on identical prompts, then flip the share over a few days. The shape parity makes this trivial.
Last updated: October 2, 2026Found a bug? admin@minedom-france.fr