# GLM-5

> GLM-5 is Z-AI's open-weight general-purpose foundation model for reasoning, coding, and agentic workloads. It has a 128K context window and 32K output. It supports thinking mode, function calling, and structured outputs.

**ID**: `z-ai/glm-5`  
**Creator**: Zhipu AI  
**Category**: text  
**Context**: 128K tokens  
**Pricing**: $0.29 / $1.29 per 1M · billed by your provider (BYOK)  
**Released**: 2026-04-15  
**Links**: [Weights on Hugging Face](https://huggingface.co/zai-org/GLM-5) · [Announcement](https://z.ai/blog/glm-5) · [Paper](https://arxiv.org/abs/2602.15763)  
**Web page**: https://anyrouter.dev/model/z-ai/glm-5

**Input modalities**: text  
**Output modalities**: text  

**Tokenizer**: GLM

**Capabilities**: chat, reasoning, streaming, function-calling, thinking

## Usage

**Endpoint**: `POST https://anyrouter.dev/api/v1/chat/completions`

```bash
curl https://anyrouter.dev/api/v1/chat/completions \
  -H "Authorization: Bearer $ANYROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "model": "z-ai/glm-5",
  "messages": [
    {
      "role": "user",
      "content": "Say hi in 3 words."
    }
  ]
}'
```

## Providers

| Provider | Input | Output |
| --- | --- | --- |
| aihubmix-byok | $0.29/M (list) | $1.29/M (list) |
| z-ai-byok | $0.29/M (list) | $1.29/M (list) |
| opencode-zen-byok | $0.29/M (list) | $1.29/M (list) |
| opencode-go-byok | $0.29/M (list) | $1.29/M (list) |
| siliconflow-byok | $0.29/M (list) | $1.29/M (list) |
| commandcode-byok | $0.29/M (list) | $1.29/M (list) |
| openrouter-byok | $1.00/M (list) | $3.20/M (list) |
| vercel-byok | $1.00/M (list) | $3.20/M (list) |
| novita-byok | $1.00/M (list) | $3.20/M (list) |
| huggingface-byok | $0.29/M (list) | $1.29/M (list) |
| inference-net-byok | $0.95/M (list) | $2.55/M (list) |
| nousresearch-byok | $1.00/M (list) | $3.20/M (list) |
| requesty-byok | $1.00/M (list) | $3.20/M (list) |
| infron-byok | $0.29/M (list) | $1.29/M (list) |
| zenmux-byok | $0.58/M (list) | $2.60/M (list) |
| llmgateway-byok | $0.57/M (list) | $2.58/M (list) |
| orcarouter-byok | $0.29/M (list) | $1.29/M (list) |
| aimlapi-byok | $1.00/M (list) | $3.20/M (list) |
| nano-gpt-byok | $0.29/M (list) | $1.29/M (list) |
| edenai-byok | $0.29/M (list) | $1.29/M (list) |
| ofox-byok | $0.29/M (list) | $1.29/M (list) |
| fluence-byok | $0.61/M (list) | $1.96/M (list) |
| qiniu-byok | $0.29/M (list) | $1.29/M (list) |
| jiekou-byok | $0.29/M (list) | $1.29/M (list) |

BYOK routes are billed by your own provider key — AnyRouter charges $0. Rates marked (list) are the provider's published list price.

## Benchmarks

- **GPQA Diamond**: 0.8
- **HLE**: 0.3
- **τ²-Bench Telecom**: 1.0
- **SciCode**: 0.5
- **OTIS Mock AIME**: 0.8

Benchmark data from [Epoch AI](https://epoch.ai/benchmarks) (CC-BY 4.0).

## Model card

- License: MIT, open weights (https://huggingface.co/zai-org/GLM-5) [1]

### Links

- announcement: https://z.ai/blog/glm-5
- model card: https://huggingface.co/zai-org/GLM-5
- paper: https://arxiv.org/abs/2602.15763

### Sources

1. [GLM-5 model card](https://huggingface.co/zai-org/GLM-5) (accessed 2026-11-11)
2. [GLM-5 blog](https://z.ai/blog/glm-5) (accessed 2026-11-11)
