Skip to content

GLM-5.2 Air API

128K context · Released Jul 8, 2026 · By Z.ai · MIT

GLM-5.2 Air costs $0.17 per million input tokens and $0.62 per million output tokens, against an official rate of $0.28 and $1.1 — 43% below official pricing. It is a Z.ai model under the MIT licence, with a 128K context window, callable through an OpenAI-compatible endpoint with the model id `z-ai/glm-5.2-air`. This model is listed for reference and is not currently served by an upstream provider, so requests for it return no available channel.

Not currently available. No configured upstream serves this model, so a request for it returns no available channel. The rate below is what it will cost when it is enabled.

Input

$0.17/M

$0.28/M

Output

$0.62/M

$1.10/M

Savings

43%

off official

  • No markup
  • OpenAI SDK compatible
  • No minimum spend
  • MIT

GLM-5.2 distilled for latency and cost. The right default for high-volume classification, extraction and routing steps inside a larger pipeline.

Copy this and go

The model id is already filled in. Nothing in this snippet needs editing except your key.

from openai import OpenAI

client = OpenAI(
    api_key="YOUR_API_KEY",
    base_url="https://router.xark.io/api/v1"   # ← the only line that changes
)

response = client.chat.completions.create(
    model="z-ai/glm-5.2-air",
    messages=[{"role": "user", "content": "Hello"}]
)

GLM-5.2 Air pricing across providers

Rates as published by each provider. We update these when they change; if you spot one that's stale, tell us and we'll fix it.

ProviderInputOutput
AI Token Router$0.17/M$0.62/M
Official (Z.ai)$0.28/M$1.10/M
OpenRouter$0.27/M$1.07/M
DeepInfra$0.20/M$0.75/M
Together AI$0.26/M$1.00/M

Cached input on GLM-5.2 Air is billed at $0.034/M — roughly 80% below the standard input rate. For agent loops with a large fixed system prompt this is usually the number that matters most.

What it's good at

  • High-throughput classification and extraction
  • Cheap router/planner step in front of a larger model
  • Real-time chat where latency beats depth
Full technical documentation

Related

Other text models

Start using GLM-5.2 Air today

$5 in free credits, no credit card required.