# Zhipu: z-ai/glm-5.2

- Model ID: `z-ai/glm-5.2`
- Provider: Zhipu
- Web version: https://www.moleapi.com/en/models/zhipu/glm-5.2
- Content status: alias

## Model introduction

GLM-5.2 is Z.AI's text model for long-horizon coding and engineering, with 1M context, 128K output, and configurable reasoning effort.

## Model capabilities

- OpenAI compatible
- Reasoning

### Verified specifications

- Official positioning: Long-horizon coding and engineering
- Context window: 1,000,000 tokens
- Maximum output: 128,000 tokens
- Verified capabilities: reasoning_effort, functions, structured output, MCP

## Model pricing and access

Pricing is supplied dynamically by the MoleAPI console API.

### Standard (default, x1)

- Input: $0.87 / 1M tokens
- Output: $3.48 / 1M tokens
- Cache read: $0.19 / 1M tokens

### Access protocols

| Protocol | Method | Endpoint |
| --- | --- | --- |
| openai | POST | /v1/chat/completions |

- Live pricing source: https://home.moleapi.com/api/pricing

## About z-ai/glm-5.2

GLM-5.2 is Z.AI's text model for long-horizon coding and engineering, with 1M context, 128K output, and configurable reasoning effort.

### Best for

Project-scale code review, refactoring and migration, long-document analysis, and engineering agents using MCP or functions.

### Core strengths

- A 1M context window fits complete repositories and large engineering evidence sets.
- reasoning_effort tunes depth for complex tasks.
- Supports functions, streaming tool calls, structured output, caching, and MCP.

### Limitations

- It is text-focused; images, video, and GUI understanding need a vision model.
- Very long input and 128K output require max_tokens limits and caching.

### Selection and production evaluation

Start a z-ai/glm-5.2 evaluation by mapping its official positioning to real work: Project-scale code review, refactoring and migration, long-document analysis, and engineering agents using MCP or functions. The first pass should exercise both its main strength, "A 1M context window fits complete repositories and large engineering evidence sets.", and its known limitation, "It is text-focused; images, video, and GUI understanding need a vision model.", instead of relying on a single subjective general-chat comparison.

For access, MoleAPI currently lists openai protocols and the Standard billing groups for this Zhipu model; the default price summary is Input $0.87 / 1M tokens · Output $3.48 / 1M tokens. Pricing, protocols, and groups come from the live catalog, so production planning should still price representative requests using real context length, output size, and cache-hit assumptions.

No independent ranking is shown unless it matches this exact model ID and reasoning profile, so nearby variants are not used as a proxy. Before launch, pin the model ID, prompt, and sample set, then compare task accuracy, structured-output validity, tool-call success, and timeout rates under the same conditions.

The model material on this page was last checked on 2026-07-24. When upstream model cards, context limits, or tool support change, update the cited bilingual facts before changing the recommendation; live MoleAPI price changes remain separate and update from the catalog automatically.

### Sources

- [B.AI GLM-5.2 model guide](https://docs.b.ai/llmservice/models/glm-5-2/) — B.AI
- [Z.AI GLM-5 series documentation](https://docs.z.ai/guides/llm/glm-5) — Z.AI
- Last verified: 2026-07-24

## Code examples

### cURL

```bash
curl https://api.moleapi.com/v1/chat/completions \
  -H "Authorization: Bearer $MOLEAPI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"z-ai/glm-5.2","messages":[{"role":"user","content":"Hello"}]}'
```

## More related models

- [glm-5.2](https://www.moleapi.com/en/models/zhipu/glm-5.2) — Zhipu
- [glm-5.3](https://www.moleapi.com/en/models/zhipu/glm-5.3) — Zhipu
- [glm-5.1](https://www.moleapi.com/en/models/zhipu/glm-5.1) — Zhipu

## Frequently asked questions

### How is z-ai/glm-5.2 priced?

Prices are read from the MoleAPI console API and update with model prices, context tiers, and account groups.

### How can I access z-ai/glm-5.2?

The catalog currently lists openai.

### How do I switch an existing project to z-ai/glm-5.2?

Keep the MoleAPI API address and key, replace the model parameter, and check protocol-specific parameters.

### Where do the z-ai/glm-5.2 details come from?

Capabilities and limitations are checked against B.AI and the other cited pages; pricing and protocols come from the MoleAPI console.
