Anthropic · Text · API

Claude API — ruble pricing and a 5-minute setup

Claude API with ruble billing: Opus, Sonnet and Fable through one Zerocoder key. Input and output per 1M tokens, streaming, Anthropic and OpenAI SDK.

What Claude models do

Claude is a family of text models from Anthropic for chat, code generation, document analysis, and vision tasks. The lineup spans several generations and tiers: Sonnet models for everyday chat and coding help, Opus models for harder reasoning and longer analysis, and Fable at the top of the range. Every model in the family also reads images passed as content parts, so you can send a screenshot or a scanned page alongside a text prompt.

What Zerocoder adds

Zerocoder gives you one API key and one ruble wallet that covers every Claude model listed in GET /v1/models, so you don't manage separate accounts or currencies. Top up the wallet with a Russian card or a company invoice straight from the cabinet — no foreign card or VPN required. Documentation is in the API docs, and both the Anthropic SDK and the OpenAI SDK work without changes once you point their baseURL at Zerocoder.

How a request and response work

Send a POST request to /v1/messages for the Anthropic format or /v1/chat/completions for the OpenAI format, with your key in the Authorization header and the model id in the body. Add stream: true to get the answer token by token, which suits chat interfaces. Before generation Zerocoder reserves an estimated cost from your input and max_tokens; once the model finishes, the real usage is charged and the difference goes back to your balance. If the provider itself fails, the charge is refunded automatically in the same response.

Models and prices

The live GET /v1/models price list in rubles and dollars. Where we are cheaper, the vendor's official price for the same unit is struck through. Minimum per call: 0.5 ₽. Endpoints: /v1/messages, /v1/chat/completions

Model prices in rubles and dollars; where we are cheaper, the vendor's official price for the same unit is struck through
ModelPriceUnitDiscount
Claude Opus 5recommendedclaude-opus-5 · Anthropicalso: claude-custom-opus, claude-opus
Official price: input 450 ₽ / output 2250 ₽, Zerocoder price: input 198 ₽ / output 990 ₽$2.20 / $11.00per 1M tokensofficial: 3:1 blend · $5 in / $25 out-56%
Claude Sonnet 4.6claude-sonnet-4.6 · Anthropicalso: claude-custom-default, claude-sonnet
Official price: input 270 ₽ / output 1350 ₽, Zerocoder price: input 119 ₽ / output 594 ₽$1.32 / $6.60per 1M tokensofficial: 3:1 blend · $3 in / $15 out-56%
Claude Sonnet 5claude-sonnet-5 · Anthropic
Official price: input 180 ₽ / output 900 ₽, Zerocoder price: input 114 ₽ / output 570 ₽$1.27 / $6.34per 1M tokensofficial: 3:1 blend · $2 in / $10 out-36%
Claude Opus 5.5claude-opus-5.5 · Anthropic
input 382 ₽ / output 1910 ₽$4.24 / $21.22per 1M tokens—
Claude Sonnet 5.5claude-sonnet-5.5 · Anthropic
Official price: input 180 ₽ / output 900 ₽, Zerocoder price: input 145 ₽ / output 727 ₽$1.62 / $8.08per 1M tokensofficial: 3:1 blend · $2 in / $10 out-19%
Claude Fable 5claude-fable-5 · Anthropicalso: claude-custom-fable
Official price: input 900 ₽ / output 4500 ₽, Zerocoder price: input 726 ₽ / output 3630 ₽$8.07 / $40.33per 1M tokensofficial: 3:1 blend · $10 in / $50 out-19%
Claude Opus 4.6claude-opus-4.6 · Anthropic
Official price: input 450 ₽ / output 2250 ₽, Zerocoder price: input 198 ₽ / output 990 ₽$2.20 / $11.00per 1M tokensofficial: 3:1 blend · $5 in / $25 out-56%
Claude Opus 4.8claude-opus-4.8 · Anthropic
Official price: input 450 ₽ / output 2250 ₽, Zerocoder price: input 198 ₽ / output 990 ₽$2.20 / $11.00per 1M tokensofficial: 3:1 blend · $5 in / $25 out-56%
Claude Opus 4.7claude-opus-4.7 · Anthropic
Official price: input 450 ₽ / output 2250 ₽, Zerocoder price: input 198 ₽ / output 990 ₽$2.20 / $11.00per 1M tokensofficial: 3:1 blend · $5 in / $25 out-56%
Struck-through prices are the vendors’ official rates from their own pages: Anthropic — checked 4 October 2026. Dollars at the internal rate 1 $ = 90 ₽; the Zerocoder price includes ruble billing and no-VPN access. Comparison assumptions:
  • text: both Zerocoder and the vendor price input and output separately; the badge blends both the same way — 3 : 1 (input : output), with input and output shown separately in the row. A different output share shifts the saving slightly. The per-call minimum (min_rub in GET /v1/models) is not included: a very short request costs at least the minimum and can come out above the official price

Cost calculator

Pick a model and a volume — the calculator uses the same formulas as API billing.

per call0.891 ₽ $0.0099
per month · 1,000891 ₽ $9.90

input 198 ₽ / output 990 ₽ per 1M tokens

minimum per call: 0.5 ₽

Prices from GET /v1/models, internal exchange rate. Failed generations are not charged.

  1. Get a keyin the API dashboard
  2. Top up the walletin rubles: card, SBP or invoice
  3. Make the callPOST /v1/messages, model claude‑opus
First request

Connect the Claude API: change two values

The Anthropic SDK in Python and Node.js, the OpenAI SDK or curl: swap the base URL and the key — requests, streaming and response handling stay as they are. Claude answers on POST /v1/messages and /v1/chat/completions.

Base URL · Anthropic SDK
https://zerocoder.com/api

OpenAI SDK and curl — https://zerocoder.com/api/v1

Model in the samples — claude-opus; any model from the table works

from anthropic import Anthropic client = Anthropic(    # without /v1: the SDK appends /v1/messages itself    base_url="https://zerocoder.com/api",    api_key="zc-sk-…",) msg = client.messages.create(    model="claude-opus",    max_tokens=300,    messages=[{"role": "user", "content": "Hello!"}],)print(msg.content[0].text)
import Anthropic from "@anthropic-ai/sdk"; const client = new Anthropic({  // without /v1: the SDK appends /v1/messages itself  baseURL: "https://zerocoder.com/api",  apiKey: "zc-sk-…",}); const msg = await client.messages.create({  model: "claude-opus",  max_tokens: 300,  messages: [{ role: "user", content: "Hello!" }],});console.log(msg.content[0].text);
import OpenAI from "openai"; const client = new OpenAI({  baseURL: "https://zerocoder.com/api/v1",  apiKey: "zc-sk-…",}); const r = await client.chat.completions.create({  model: "claude-opus",  messages: [{ role: "user", content: "Hello!" }],});console.log(r.choices[0].message.content);
# Anthropic Messages formatcurl https://zerocoder.com/api/v1/messages \  -H "x-api-key: zc-sk-…" \  -H "content-type: application/json" \  -d '{"model": "claude-opus", "max_tokens": 400,       "messages": [{"role": "user", "content": "Hello!"}]}' # OpenAI chat/completions format, streamingcurl -N https://zerocoder.com/api/v1/chat/completions \  -H "authorization: Bearer zc-sk-…" \  -H "content-type: application/json" \  -d '{"model": "claude-opus", "stream": true,       "messages": [{"role": "user", "content": "Hello!"}]}'
// Live price comparisonclaude-opus · per 1M tokens
  • Zerocoder-56%input $2.20 / output $11.00
  • Official APIinput $5.00 / output $25.00

Anthropic list price (Claude Opus 5); bars and discount compare both prices blended 3 : 1 (input : output); checked 4 October 2026

How to connect the Claude API: first request in 5 minutes

From a key to production — six steps based on the real /api/v1 contracts. Each step links to the relevant docs section.

  1. 1

    Get a key in your account

    Sign up, open the API section of your account, top up the balance in rubles and create a zc-sk-… key. One key unlocks Claude and every other model in the catalogue.

    Read more →
  2. 2

    Send the first request

    POST /v1/chat/completions (Bearer) or /v1/messages (x-api-key) with model and messages — OpenAI and Anthropic shapes, the SDKs work with a swapped base URL.

    Read more →
  3. 3

    Turn on streaming

    stream: true — the answer arrives as SSE chunks with a final billing event showing the real charge. The reserve is taken by max_tokens (default 8192), so set it to fit the task.

    Read more →
  4. 4

    Handle limits and errors

    30 requests per minute per key: on 429 wait and retry with a growing pause; 402 — top up the balance; 400 — check model against GET /v1/models. Failed generations are not charged, so retrying is safe.

    Read more →
  5. 5

    Watch the budget

    GET /v1/balance returns the balance and 30-day spend; every call's price comes back in the response — write it to your logs and set an alert threshold in your own monitoring.

    Read more →
  6. 6

    Ship to production

    Keep the key in server secrets, never in the frontend. For high Claude volumes contact us — the limit is raised individually and companies can pay by invoice. Check the observed stability on the status page.

    Read more →

No code

Any tool that can make an HTTP request can call our API: one POST with the x-api-key header.
HTTP Requestn8n

HTTP Request node: POST to the /api/v1 endpoint, x-api-key header and a JSON body built from workflow fields. For video add a Wait node and a second HTTP Request on GET ?id= in a loop until completed.

HTTP → Make a requestMake

HTTP “Make a request” module: POST, Body type JSON, x-api-key header. The response is parsed automatically — the image url or the answer text flows into the next modules.

Webhooks by ZapierZapier

Webhooks by Zapier → Custom Request action: POST, Data — JSON with model and prompt, Headers — x-api-key. Response fields are available to the following Zap steps.

Apps ScriptGoogle Sheets

In Apps Script use UrlFetchApp.fetch with method post, contentType application/json and a payload from the cells: prompts in one column, results written to the next one.

any bot frameworkTelegram bot

A bot on aiogram, grammY or Telegraf calls the same HTTP API: user message → model request → reply in the chat. For video — poll the status and send the file from the finished URL.

OpenAI-compatible base URLPython / Node SDK

For text models the official OpenAI and Anthropic SDKs work with a swapped base URL and our key — your application code stays the same. Images and video are a plain HTTP call from any language.

For business

We'll help bring AI into your business

More than a key: we help wire Claude and other models into your workflows — from audit to production, with invoice payment.

  • Process auditWe find where AI pays off in your workflows: support, sales, content, documents — and name specific scenarios and models.
  • Integration into CRM, website, Telegram, n8nWired through our API or ready no-code scenarios; one key and a shared balance for every model.
  • Ruble payment by invoiceCompanies get an invoice for bank transfer, accounting documents and a top-up of the API balance.
  • Support and limitsHelp with prompts and architecture, request limits raised individually for your load.

Inputs, limits and refunds

  • Two shapes: Anthropic Messages (/v1/messages, x-api-key) and OpenAI chat/completions (Bearer)
  • Streaming: Anthropic SSE with a billing event at the end; OpenAI chunks and data: [DONE]
  • Input and output tokens are billed at their own per-1M prices (output costs more), minimum per call in min_rub
  • A reserve by max_tokens (default 8192) is taken before the answer and settled after
  • Failure before the first token — the reserve is refunded
  • Image input only via the separate vision model (model: vision); images sent to the models on this page return 400 model_no_vision with nothing charged
  • 30 requests per minute per key (all endpoints combined); model: smart picks the model tier itself

Error responses and refunds

# 401 {"type":"error","error":{"type":"authentication_error","message":"Invalid or revoked API key."}}
# 402 {"type":"error","error":{"type":"billing_error","message":"Not enough API balance: …"}}
# 429 {"type":"error","error":{"type":"rate_limit_error","message":"…"}}   ← 30 requests/min per key
# 400 {"type":"error","error":{"type":"invalid_request_error","message":"Unknown model \"…\". See GET /v1/models."}}
# /chat/completions uses the OpenAI envelope: {"error":{"message":"…","type":"…","code":"insufficient_balance"}}
# streaming: the reserve (by max_tokens) is settled after the answer; a failure before the first token is refunded
# event: billing {"charged_rub":…,"reserved_rub":…,"balance_rub":…,"unit":"1M_tokens","rub_per_mtok_in":…,"rub_per_mtok_out":…,"rub_per_mtok":…}

Observed stability of the API and text models

Numbers come from the public /status summary: the share of successful requests over a period for the whole API and for the category as a whole (the summary has no per-model breakdown), no SLA promises. Failed generations are not charged, so retrying is safe.

Developer APIoperational

—now (2 h window)
78.5%last 30 days
78.5%last 90 days

Text & chatoperational

—now (2 h window)
92%last 30 days
89%last 90 days

Refunds and charges

  • Failure before the first token — the reserve is refunded in full
  • The max_tokens reserve is settled after the answer — only the real volume is charged
  • In streaming the real charge arrives as the billing event

Tracking since Aug 6, 2026.

Use cases

1

Build a support chatbot that answers customer questions and escalates hard cases to a human agent

2

Add a code review assistant to internal dev tools that comments on pull requests automatically

3

Run a document pipeline that summarizes contracts and pulls out key clauses in bulk

4

Build a vision-enabled app that turns screenshots or scanned forms into structured text

5

Power an indie SaaS writing tool that drafts and edits marketing copy on request

6

Automate internal reporting by turning raw data exports into plain-language summaries for your team

Prompting tips

  • Set a system message to fix the assistant's role and tone for the whole conversation, not just one reply
  • State the output format in the prompt — ask directly for JSON or markdown if you need structured text
  • Set max_tokens to match the expected reply length; the default reservation covers long answers, not short ones
  • Lower temperature for consistent, repeatable output like data extraction; raise it for varied, creative writing
  • Use stream: true for chat UIs, and pick the cheap tier for simple replies and the top tier for complex reasoning

Ready-made prompts for Claude

Copy the prompt and the parameters into the request body — the fields are named exactly as in the /api/v1 contract. Replace the angle-bracket placeholders with your material.

Contract risk review

List the five biggest risks for the contractor in this agreement and propose a redline for each:

<contract text>
system: You are a legal analyst. Be brief, use bullet points, no filler.max_tokens: 1200

Support reply in brand voice

The customer writes: “The order was an hour late and the food was cold.” Draft a reply under 80 words.
system: You are a support agent for a food delivery service. Friendly tone, no corporate speak. Do not promise compensation.max_tokens: 300

Extract data as JSON

From the email below extract company, contact_name, email, budget, deadline (ISO date or null):

<email>
system: Return valid JSON only, no explanations.max_tokens: 400

Summarise a long document

Summarise the report in ten bullet points for an executive: conclusions, key figures, risks and decisions to make:

<report>
max_tokens: 900stream: true

Code review

Review the function for bugs, security and readability:

<code>
system: You are a senior developer. Answer as a list of findings: severity, line, suggestion.max_tokens: 1000

Who the Claude API is for

Industries where this kind of generation becomes part of the workflow rather than an experiment.

SaaS & appsAn AI assistant inside your product: OpenAI or Anthropic shape, Claude via a swapped base URL.
Support & CRMTicket replies, classification, conversation summaries for managers.
E-commerceProduct descriptions, SEO copy, review replies — in bulk across the catalogue.
EdTechGrading, explanations at the learner's level, quiz generation.
Documents & legalDigests, version comparison, field extraction into structured data.
Media & contentArticle drafts, rewrites, headlines and translations — Claude in the editorial pipeline.

FAQ

How much does the Claude API cost in rubles per token?

Claude is billed per token: the table above shows two prices per million tokens for each model — input and output (output costs several times more), plus a minimum price per call (min_rub in GET /v1/models). Before the answer max_tokens is reserved at the output price; after it the actual usage is charged and the difference is returned — the final figure is in the billing event of the stream.

How do I connect the Claude API in Python with the Anthropic SDK?

Two ways. The official Anthropic SDK: set base_url to zerocoder.com/api (without /v1 — the SDK appends /v1/messages itself) and a zc-sk-… key — the rest of the code stays the same. Or the OpenAI SDK or requests against /v1/chat/completions with a Bearer header and the same key. Ready Claude samples for Python, Node.js and the shell are in the “First request” block.

What are the Claude API limits: context, max_tokens, rate?

Context length is bounded by the Claude model itself — the provider's input limit plus max_tokens for the answer; when max_tokens is omitted the reserve uses the default value, and inflating it needlessly is unwise because the reserve is held until the answer ends. A key has a shared limit of 30 requests per minute across all API endpoints; above it you get 429 rate_limit_error.

Which Claude model should I choose, and how do I specify its id?

The short ids claude-opus and claude-sonnet are pinned to specific versions (see the aliases field in GET /v1/models); call newer versions by their exact id from the table. Sonnet is the workhorse for agents and analytics, Opus is for hard reasoning and code. The provider retired Haiku and claude-haiku now returns an error with a hint: use gpt-luna for fast, cheap jobs. The response names the model actually used.

Are tokens charged if the Claude API returns an error?

If Claude never starts answering — the provider is down or the request is rejected — the reserve returns to the balance in full and automatically. If the answer starts and then breaks, only what was actually generated per usage is charged. Request validation errors (400) and rate limiting (429) charge nothing.

Can we pay for the Claude API by corporate invoice?

Yes. A company requests an invoice in the API account and pays it from the corporate account; once credited, the amount sits on the API balance and is spent on Claude and any other model with the same key. A Russian bank card gives an instant top-up, accounting documents come on request. No Anthropic account or foreign-currency card is needed.

Are there free tokens for the Claude API?

There are no free starter tokens in the API: the wallet opens with a minimum first top-up, after which Claude is charged on actual usage with a per-call minimum. You can talk to Claude for free and tune the system prompt in the Zerocoder studio and the Claude tool in the catalogue, then move the prompt into a /v1/messages request.

Does the Claude API support streaming and image input?

Yes. Streaming is enabled with stream: true: in the Anthropic format you receive SSE events and a final billing event with the exact charge, in the OpenAI format chunks and data: [DONE]. Up to 4 images per user message are accepted as input (vision is in beta: a dedicated vision model handles them, its name is in the model field of the response, and the price is that of the requested Claude model).

AI API for your product

Up to -56% vs the official API · ruble billing, no VPN