z-ai
Z.ai: GLM 5.2
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,...
Context
1M tokens
Input / 1M tokens
$0.93
Output / 1M tokens
$3
Benchmark
—
Pricing
Input tokens$0.93 per 1M tokens
Output tokens$3 per 1M tokens
Cache read$0.18 per 1M tokens
Technical details
Model IDz-ai/glm-5.2
Context window1M tokens
Input modalitiestext
Output modalitiestext
TokenizerOther
Max output tokens32,768
Use with MegaBrain
import OpenAI from 'openai'
const client = new OpenAI({
baseURL: 'https://getmegabrain.com/api/gateway/v1',
apiKey: process.env.MEGABRAIN_API_KEY,
})
const response = await client.chat.completions.create({
model: 'z-ai/glm-5.2',
messages: [{ role: 'user', content: 'Hello!' }],
})