z-ai logo
z-ai

Z.ai: GLM 5.2

Source description (English)

GLM 5.2 is a large-scale reasoning model from Z.ai. It supports text input and output with a 1M-token context window, and is suited for long-horizon agent workflows, project-level software engineering,...

Overview

Model specifications

Context
1,048,576 tokens
Maximum output
943,718 tokens
Architecture
text->text
Tokenizer
Other
Knowledge cutoff
Not provided
Moderated
No
OPENROUTER

Complete pricing

Synchronized OpenRouter rates. Token prices are shown per one million tokens.

Input
$0.007
per 1M tokens
Output
$6.8
per 1M tokens
Cache read
$0.006
per 1M tokens
API

Model configuration

Default parameters

temperature
1
top_p
0.95

Reasoning

Reasoning required
No
Default parameters
high
Capabilities
xhigh, high, none
API

Quick start

Set OPENROUTER_API_KEY locally. Python requires requests; JavaScript runs in Node.js. Keep the key on the server.

API documentation

curl --fail-with-body https://openrouter.ai/api/v1/chat/completions \
  -H "Authorization: Bearer $OPENROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"z-ai/glm-5.2","messages":[{"role":"user","content":"Hello!"}]}'
Capabilities

Input → Output

Input
text
Output
text
Reasoning

Yes · xhigh · high · none

API

Supported API parameters

frequency_penaltyinclude_reasoninglogit_biaslogprobsmax_tokensmin_ppresence_penaltyreasoningreasoning_effortrepetition_penaltyresponse_formatseedstopstructured_outputstemperaturetool_choicetoolstop_ktop_logprobstop_p
Available providers

33 providers

Checked: November 19, 2026

Live providers on OpenRouter

Provider availability, latency, throughput and routing can change continuously. Open the source page for current operational data.

OpenRouter

Relace

fp4
Context
1.0M
Maximum output
131K
Input
$0.0066
Output
$7.9833
Cache read
$0.0066
Cache write
Not provided

Wafer

fp4
Context
1.0M
Maximum output
944K
Input
$0.007
Output
$6.8
Cache read
$0.006
Cache write
Not provided

Wafer

fp4
Context
1.0M
Maximum output
944K
Input
$0.19
Output
$8
Cache read
$0.18
Cache write
Not provided

Cloudflare

Not provided
Context
262K
Maximum output
236K
Input
$0.19
Output
$8
Cache read
$0.19
Cache write
Not provided

DeepInfra

fp4
Context
1.0M
Maximum output
164K
Input
$0.45
Output
$1.44
Cache read
$0.084
Cache write
Not provided

DeepInfra

fp4
Context
1.0M
Maximum output
164K
Input
$0.5625
Output
$1.8
Cache read
$0.105
Cache write
Not provided

Ambient

fp8
Context
203K
Maximum output
182K
Input
$0.6
Output
$2
Cache read
$0.15
Cache write
Not provided

StreamLake

fp8
Context
1.0M
Maximum output
128K
Input
$0.6131
Output
$1.9268
Cache read
$0.1139
Cache write
Not provided

CoreWeave

fp4
Context
1.0M
Maximum output
944K
Input
$0.62
Output
$2.42
Cache read
$0.14
Cache write
Not provided

Morph

fp8
Context
1.0M
Maximum output
944K
Input
$0.643
Output
$1.978
Cache read
$0.217
Cache write
Not provided

Novita

fp8
Context
1.0M
Maximum output
131K
Input
$0.6496
Output
$2.0416
Cache read
$0.1206
Cache write
Not provided

SiliconFlow

fp8
Context
1.0M
Maximum output
262K
Input
$0.651
Output
$2.046
Cache read
$0.13
Cache write
Not provided

DigitalOcean

Not provided
Context
1.0M
Maximum output
131K
Input
$0.7
Output
$2.2
Cache read
$0.105
Cache write
Not provided

DeepInfra

fp4
Context
1.0M
Maximum output
164K
Input
$0.8438
Output
$2.7
Cache read
$0.1575
Cache write
Not provided

AtlasCloud

fp8
Context
1.0M
Maximum output
131K
Input
$0.938
Output
$2.948
Cache read
$0.1742
Cache write
Not provided

Alibaba

fp8
Context
1M
Maximum output
131K
Input
$0.966
Output
$3.036
Cache read
$0.1932
Cache write
Not provided

Alibaba

fp8
Context
1M
Maximum output
131K
Input
$1.12
Output
$3.52
Cache read
$0.224
Cache write
Not provided

Nebius

fp4
Context
1.0M
Maximum output
944K
Input
$1.4
Output
$4.4
Cache read
$0.14
Cache write
Not provided

Mistral

Not provided
Context
1.0M
Maximum output
131K
Input
$1.4
Output
$4.4
Cache read
$0.14
Cache write
Not provided

BaseTen

fp8
Context
1.0M
Maximum output
262K
Input
$1.4
Output
$4.4
Cache read
$0.14
Cache write
Not provided

Together

Not provided
Context
1.0M
Maximum output
944K
Input
$1.4
Output
$4.4
Cache read
$0.26
Cache write
Not provided

Baidu

fp8
Context
1.0M
Maximum output
131K
Input
$1.4
Output
$4.4
Cache read
$0.26
Cache write
Not provided

BaseTen

fp8
Context
1.0M
Maximum output
262K
Input
$1.4
Output
$4.4
Cache read
$0.14
Cache write
Not provided

Venice

fp8
Context
1M
Maximum output
131K
Input
$1.4
Output
$4.4
Cache read
$0.26
Cache write
Not provided

GMICloud

fp8
Context
1.0M
Maximum output
944K
Input
$1.4
Output
$4.4
Cache read
$0.26
Cache write
Not provided

Parasail

fp4
Context
262K
Maximum output
236K
Input
$1.4
Output
$4.4
Cache read
$0.26
Cache write
Not provided

Friendli

Not provided
Context
1.0M
Maximum output
944K
Input
$1.4
Output
$4.4
Cache read
$0.26
Cache write
Not provided

Z.AI

fp8
Context
1.0M
Maximum output
131K
Input
$1.4
Output
$4.4
Cache read
$0.26
Cache write
Not provided

Mistral

Not provided
Context
1.0M
Maximum output
128K
Input
$1.54
Output
$4.84
Cache read
$0.154
Cache write
Not provided

BaseTen

fp8
Context
1.0M
Maximum output
262K
Input
$2.1
Output
$6.6
Cache read
$0.21
Cache write
Not provided

BaseTen

fp8
Context
1.0M
Maximum output
262K
Input
$2.1
Output
$6.6
Cache read
$0.21
Cache write
Not provided

Baidu

fp4
Context
1.0M
Maximum output
131K
Input
$2.25
Output
$7.88
Cache read
$0.56
Cache write
Not provided

Alibaba

fp8
Context
1M
Maximum output
131K
Input
$2.31
Output
$7.26
Cache read
$0.462
Cache write
Not provided
z-ai

4 models

All models