AnthropicAI provider

Anthropic's Claude models, now on TokenRex

Every current Claude family is available on TokenRex, from the deep-reasoning Claude Fable 5.1 to the fast, low-cost Claude Haiku 4.5. Call them with Anthropic's own Messages API format — so Claude Code and the Anthropic SDK work — or with the OpenAI-compatible endpoint, using the same TokenRex key.

Models available
28
Model families
5
Types
1
Dario Amodei of Anthropic in conversation on stage at TechCrunch Disrupt 2023
Dario Amodei of Anthropic (right) at TechCrunch Disrupt, 2023. Photo: TechCrunch, CC BY 2.0, via Wikimedia Commons.

Anthropic flagship models

The Anthropic models most people start with. Prices are live and update automatically.

AnthropicChat & reasoning

Claude Fable 5.1

Advanced reasoning for complex problems and long-running agent workflows.

$10.00 in · $50.00 out / 1M

claude-fable-5-1
View model details
AnthropicChat & reasoning

Claude Opus 5.5

Deep coding and sustained agent workflows for demanding professional tasks.

$4.00 in · $20.00 out / 1M

claude-opus-5-5
View model details
AnthropicChat & reasoning

Claude Opus 5

Advanced reasoning and coding for complex technical challenges.

$5.00 in · $25.00 out / 1M

claude-opus-5
View model details
AnthropicChat & reasoning

Claude Sonnet 5

A balanced model for coding, reasoning, and everyday professional work.

$2.00 in · $10.00 out / 1M

claude-sonnet-5
View model details
AnthropicChat & reasoning

Claude Haiku 4.5

Fast, efficient intelligence for everyday tasks and high-volume workloads.

$1.00 in · $5.00 out / 1M

claude-haiku-4-5
View model details

What you can do with Anthropic on TokenRex

Long coding sessions

Claude Opus and Sonnet are built for large codebases, refactors and multi-step agent work in Claude Code, Cursor and Cline.

Careful reasoning and writing

Clear, well-structured answers for analysis, research, policy and long-form writing.

Documents in prompts

Send PDFs with your prompt to summarise contracts, reports and manuals.

Prompt caching

Reuse long system prompts and documents. Cache reads and cache writes are billed at the rates shown for each model.

Fast versions

Many Claude families have Fast versions: about 2x faster responses at 2x the price.

Two API formats

Use /v1/messages (Anthropic format) or /v1/chat/completions (OpenAI format) — whichever your app expects.

Popular ways people use it

  • Claude Code and other coding agents with a TokenRex key
  • Reviewing contracts, policies and long reports
  • Research assistants that read and compare many documents
  • High-volume classification and extraction with Haiku
  • Drafting technical documentation and support replies
  • Agents that plan and run multi-step tasks

How it works

TokenRex sits between your app and Anthropic. You send a normal API request with your TokenRex key; we check the key and your balance, pass the request to Anthropic, stream the answer back, and bill the exact usage Anthropic reports.

  1. Your app

    SDK, agent or BYOK tool

  2. TokenRex

    Checks key and balance

  3. Anthropic

    Runs the Anthropic model

  4. Answer + bill

    Streamed back, billed per use

  1. 1

    Create a free account

    Sign up with email or Google. New accounts can claim free starter credit.

  2. 2

    Create an API key

    Open API keys in your dashboard and create a key. Keep it private.

  3. 3

    Point your app at TokenRex

    Set the base URL to https://tokenrex.ai/api/public in your SDK or BYOK app and paste your key.

  4. 4

    Choose a model ID

    Copy the exact model ID from the list on this page, for example from a flagship card.

  5. 5

    Pay only for what you use

    Each request is billed at the live model price and deducted from your prepaid wallet.

Python · Anthropic SDK

Configuration
import anthropic

client = anthropic.Anthropic(
    base_url="https://tokenrex.ai/api/public",
    api_key="YOUR_TOKENREX_KEY",
)

message = client.messages.create(
    model="claude-sonnet-5",
    max_tokens=1024,
    messages=[{"role": "user", "content": "Review this function for bugs."}],
)
print(message.content[0].text)

Endpoints for Anthropic models

  • POST /v1/messagesClaude Messages API format (Anthropic SDK, Claude Code)
  • POST /v1/chat/completionsOpenAI-compatible format, with streaming

All Anthropic models on TokenRex

28 models in 5 families. Open a model to see every version, cache rates and limits.

Compare models

Pricing and billing

Prepaid wallet

Top up once and every request is deducted from your balance. No subscription and no monthly minimum.

Cache-aware billing

If Anthropic reports cached input tokens, they are billed at the model's lower cache-read rate.

Fast versions

Where offered, Fast versions answer about 2x faster at 2x the price.

Anthropic on TokenRex — common questions

Does Claude Code work with TokenRex?

Yes. Claude Code talks to a Claude-compatible Messages endpoint. Follow the Claude Code guide in Integrations to set the base URL and key.

Can I call Claude with the OpenAI SDK?

Yes. Use /v1/chat/completions with a Claude model ID such as claude-sonnet-5.

Is prompt caching supported?

Yes. When Anthropic reports cached tokens, cache reads and cache writes are billed at the rates on each model page. TokenRex never charges a cached-output rate.

Which Claude model should I start with?

Claude Sonnet 5 is a balanced default. Choose Opus or Fable for the hardest reasoning and coding, and Haiku for fast, high-volume work.

Other AI providers on TokenRex

Anthropic and its logo are trademarks of their owner and are shown only to identify the models available. TokenRex is an independent service by Asirex Labs and is not affiliated with or endorsed by Anthropic.