Skip to contentFREE until Nov 30 · hy4-flash:free · $0 for every account · Try it →

AI model pricing

Hy4 Preview API

hy4-preview

44% off official

Context window
1,000,000
You save
44%

About Hy4 Preview API pricing

Hy4 Preview is available through the zrouter gateway behind one API key, alongside every other model in the catalog. Hy4 Preview API pricing is pay-as-you-go: $0.46704 per 1M input tokens and $1.40056 per 1M output tokens — no subscription, no monthly minimum, and the same OpenAI-compatible endpoint your tools already use.

Against the official API — $0.834 input and $2.501 output per 1M tokens — zrouter runs about 44% cheaper, so sustained workloads cost a fraction of list price. Every request is metered per token and settled in real time, and live rates stay visible on the pricing page. The model provides a 1,000,000 token context window, so long documents, large codebases and extended agent sessions fit in a single request.

For predictable spend, prepaid Token Plans for Hy4 Preview start at $1 and are consumed first; PAYG covers anything beyond the plan. With chat completions, responses, messages, streaming support, Hy4 Preview slots into existing OpenAI-compatible and Anthropic-compatible tooling after a one-line base-URL change — a practical fit for chat products, coding agents and batch jobs that need frontier quality without official-API prices.

Price comparison

PAYG rates · per 1M tokens

input

44%
$0.834
Official price
$0.46704
zrouter price

output

44%
$2.501
Official price
$1.40056
zrouter price

Cache read $0.046704Cache write $0.46704

Token Plan tiers

Token Plans are tied to one model. Your plan balance is used first, then PAYG covers the remainder.

$1per plan

9,810,000 tokens

$2per plan

19,620,000 tokens

$5per plan

49,050,000 tokens

$10per plan

98,100,000 tokens

Capabilities

ChatResponsesMessagesStreaming

Hy4 Preview price per 1M tokens: zrouter vs official

Pay as you go, billed per token used. The official column is the list price of the model creator; the zrouter column is what you pay.

Token typeOfficialzrouterYou save
Input$0.834$0.4670444%
Output$2.501$1.4005644%

Prices are in USD per 1,000,000 tokens. When the provider serves part of your prompt from its cache, that part is billed at a discounted read rate; the usage page shows the exact split for every request.

Context and output limits

Hy4 Preview accepts up to 1,000,000 tokens of context in one request (prompt plus answer). Set max_tokens to cap the length of the answer, and stream the response to see the first tokens sooner.

Call Hy4 Preview with your zrouter key

One zr_ key works on every endpoint. Replace the key and keep the model name hy4-preview.

curl (OpenAI-compatible)

curl https://api.zrouter.dev/v1/chat/completions \
  -H "Authorization: Bearer $ZROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model": "hy4-preview", "messages": [{"role": "user", "content": "Hello"}]}'

Python (openai SDK)

from openai import OpenAI

client = OpenAI(base_url="https://api.zrouter.dev/v1", api_key="zr_...")
reply = client.chat.completions.create(
    model="hy4-preview",
    messages=[{"role": "user", "content": "Hello"}],
)
print(reply.choices[0].message.content)

Anthropic SDK / Claude Code

export ANTHROPIC_BASE_URL="https://api.zrouter.dev"
export ANTHROPIC_AUTH_TOKEN="zr_..."
export ANTHROPIC_MODEL="hy4-preview"
claude

Get started with Hy4 Preview in three steps

  1. Sign in with Google and create an API key. The key starts with zr_ and is shown once, so store it somewhere safe.
  2. Top up a pay-as-you-go balance with QRIS, USDT or USDC, or buy a Token Plan for this model. No credit card is required.
  3. Send your first request to hy4-preview with the curl or Python example above. Usage and cost show up in your dashboard right away.

How billing works for Hy4 Preview

Every request is billed by the tokens it actually used, as reported by the model provider: input tokens and output tokens are priced separately, which is why the table above has one row for each.

If you hold a Token Plan for this model, it is spent first. When it runs out, the request falls back to your pay-as-you-go balance. If neither has funds, the gateway answers 402 instead of running the request.

The usage page lists each request with its token counts and cost, and you can export it as CSV or JSON. Your balance does not expire and is not reset on a schedule.

Why call Hy4 Preview through zrouter

Hy4 Preview API: frequently asked questions

How much does the Hy4 Preview API cost on zrouter?
Pay-as-you-go is $0.46704 per 1M input tokens and $1.40056 per 1M output tokens, 44% below the official price. You only pay for tokens you use, and the balance does not expire.
How do I call Hy4 Preview with the OpenAI SDK?
Create a zrouter key, set the base URL to https://api.zrouter.dev/v1 and use the model name hy4-preview. The request and response shapes are the same as the OpenAI Chat Completions API.
Can I use Hy4 Preview with Claude Code or the Anthropic SDK?
Yes. The gateway also speaks the Anthropic messages protocol. Point ANTHROPIC_BASE_URL at https://api.zrouter.dev, use your zr_ key as the auth token and set the model to hy4-preview.
Is there a Token Plan for Hy4 Preview?
Yes. Token Plans start at $1 and are used before your pay-as-you-go balance. The balance never expires and there is no 5-hour window.
How do I pay without a credit card?
Top up with QRIS, USDT or USDC. No credit card is needed, and one balance works for every model.

Other models you can call with the same key:

Documentation