Zhipu model on Crazyrouter
All Zhipu AI models →

GLM-5.4 API pricing and integration

GLM-5.4 through OpenAI-compatible Chat Completions: Z.ai's Loop Transformer flagship with a 1M-token context window, up to 128K output tokens and thinking mode.

Use this model via API

This model is available through the paid API. Create an account, add funds and create an API key. The $2 Playground credit is for supported text models only, not API calls.

Sign up for API access
OpenAI compatibleReasoningCodingVisionLong context
Get API KeyView live pricing

Paste the model ID, live price, base URL and a working request straight into your coding agent.

Zhipu AI
glm-5.4
Input / 1M tokens$1.20
Output / 1M tokens$4.18
Cached input / 1M tokens$0.300
Model ID
glm-5.4
Provider
Zhipu
Endpoint
/v1/chat/completions
Task
chat
Context window
1M tokens
Input modalities
Text, image, video
Output modalities
Text

What is GLM-5.4?

Use the exact API model ID glm-5.4 with /v1/chat/completions; the page URL uses glm-5-4, but requests need the dot. Z.ai released GLM-5.4 on November 23, 2026 as its latest flagship and its first model built on the Loop Transformer architecture, which runs a block of middle layers twice instead of adding parameters. Z.ai documents a 1M-token context window, up to 128K output tokens, thinking mode, streaming, function calling, context caching and structured JSON output, with text, image, video and file input. Z.ai also notes that the model can fall into very long thinking loops on some tasks, so set max_tokens and a client timeout, and measure output tokens on your own workload before budgeting. GLM-5.3 and GLM-5 remain separate model IDs with their own rates. The table below shows the live Crazyrouter input, output, cache-read and cache-write rates; this page quotes no vendor list price because Z.ai had not published a pay-as-you-go rate for GLM-5.4 when it was last reviewed.

Drop-in OpenAI compatibility

Works with the OpenAI SDKs, LangChain, Cursor, Cline and any tool that accepts a custom base URL.

Streaming and tool use

Streaming, tools and structured output depend on the model and upstream channel. Check the required feature on your channel before production use.

Live usage pricing

The rates come from Crazyrouter's billing table; discounts vary by model.

One account for every model

Compare against Claude, GPT, Gemini, DeepSeek and more without juggling vendor accounts.

GLM-5.4 API quickstart

Point your OpenAI SDK at https://api.crazyrouter.com/v1 and set the model to glm-5.4.

cURL
curl https://api.crazyrouter.com/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $CRAZYROUTER_API_KEY" \
  -d '{
    "model": "glm-5.4",
    "messages": [{"role": "user", "content": "Explain the tradeoffs of this architecture decision."}],
    "stream": true
  }'

Estimated workload costs

Chatbot · per month
$221
100k conversations × 800 input / 300 output tokens
Documents · per 1k documents
$16
8k input / 1.5k output tokens each
Coding · per developer / month
$4.07
2M input / 400k output tokens

Best use cases

Coding assistants and agent loops with tool calls
Long-document analysis, summarisation and extraction
Customer-facing chat with streaming responses
Evaluation and A/B tests across model vendors
Batch classification, tagging and structured extraction
Technical writing, design docs and code review

Works with developer tools

OpenAI SDKs

Set base_url to https://api.crazyrouter.com/v1 and model to glm-5.4.

Cursor, Cline, Continue

Add Crazyrouter as a custom OpenAI-compatible provider and pick the model from the list.

LangChain / LlamaIndex

Use the OpenAI chat model class with the Crazyrouter base URL.

GLM-5.4 FAQ

What base URL do I use for GLM-5.4?

https://api.crazyrouter.com/v1. Chat completions go to /v1/chat/completions.

How is usage billed?

Per token, at the input/output rates shown on this page. Your balance is debited per request; there is no subscription.

Does it support streaming and function calling?

Support varies by model and upstream channel. The request example is a starting point; verify streaming, tools and structured output separately before production use.

Can I switch to another model later?

Change the model string. The same key works for every model in the Crazyrouter catalogue.

Where do I see the current price?

The pricing page lists live rates for every model, including group discounts if you are logged in.

Guides and comparisons

Podcast

AI Dev Tools: The Crazyrouter Podcast

Short episodes for developers on AI APIs, gateways, cost control and coding tools.

Latest episodes

  • EP196 · Oct 29, 2026 · 6:53

    AI API Security Posture — Turn Controls Into Continuous Evidence

    A practical guide to AI API security posture: inventory exposure, verify controls continuously, protect keys and data, constrain tools, and turn security assumptions into evidence that operators can act on.

  • EP195 · Oct 28, 2026 · 7:21

    AI API Policy Drift — Detect When Production Rules Stop Matching Intent

    A practical guide to policy drift in AI APIs: version routing and safety rules, detect stale enforcement, compare intended and observed behavior, and restore control before small gaps become incidents.

Episodes with written show notes →