Model details
claude-sonnet-4-6 API Pricing and Integration
Access claude-sonnet-4-6 through ZHUAN, check current token prices and make text requests with the OpenAI-compatible API or Anthropic Messages format.
Current prices
claude-sonnet-4-6Current prices for new keys · USD per million tokens
- Input
- $0.88803
- Output
- $4.438184
- Cache read
- $0.089017
- Cache write
- $1.109501
Daily sync · 23 models ·
How do I call claude-sonnet-4-6?
Use claude-sonnet-4-6 as the request model ID. The OpenAI-compatible endpoint is https://key.zhuan.xyz/v1/chat/completions, with a key from the ZHUAN console. The example reads ZHUAN_API_KEY from the environment; generation incurs usage charges.
import os
from openai import OpenAI
client = OpenAI(
api_key=os.environ["ZHUAN_API_KEY"],
base_url="https://key.zhuan.xyz/v1",
max_retries=0,
)
response = client.chat.completions.create(
model="claude-sonnet-4-6",
messages=[{"role": "user", "content": "Hello"}],
)
print(response.choices[0].message.content)
Anthropic Messages example
Set the Anthropic Python SDK base_url to https://key.zhuan.xyz/proxy. This example limits output to 128 tokens. Adjust it for your task and validate supported parameters first.
import os
from anthropic import Anthropic
client = Anthropic(
api_key=os.environ["ZHUAN_API_KEY"],
base_url="https://key.zhuan.xyz/proxy",
max_retries=0,
)
message = client.messages.create(
model="claude-sonnet-4-6",
max_tokens=128,
messages=[{"role": "user", "content": "Hello"}],
)
for block in message.content:
if block.type == "text":
print(block.text)
How should I evaluate this model for my tasks?
Evaluate the model with your own coding questions, document tasks or conversation examples before using it in production. Test output formats, system prompts and tools separately; a text example does not validate every capability.
How do I check request charges?
This page shows prices for newly created keys, in USD per million tokens, from the same daily-synced data as the price catalog. Existing key prices are shown in the console. After a request, check the model, input, output and cache tokens and the actual charge in request history. The public catalog does not promise a fixed per-request cost.
What should I check before integration?
- The catalog and prices change. A catalog entry does not guarantee availability for every request; check the status and request ID if a model is unavailable.
- Context, output limits, concurrency and advanced parameters depend on actual service responses. Validate a small request before increasing load.
- Retries, timeouts and interrupted streams may still incur usage. Contact support with the request ID if a charge appears incorrect.