GLM-5.1

glm-5.1 by Z.ai Released April 8, 2026
Reasoning · Function calling · Structured output · Prompt caching · EU hosting · Up to 35% off
Input from
$0.91 / 1M
Output from
$2.86 / 1M
Cached input from
$0.169 / 1M
Context window
203K
Endpoints
4
from 4 providers
Regions
Global, Asia, Europe, United States

About GLM-5.1

GLM-5.1 delivers a major leap in coding capability, with particularly significant gains in handling long-horizon tasks.

GLM-5.1 is a chat model by Z.ai, available on Eden AI through 4 endpoints from 4 providers, from $0.91 per million input tokens and $2.86 per million output tokens, with a context window of up to 203K tokens.

Providers and prices

4 endpoints from 4 providers, cheapest first, in USD per million tokens. Every one is called with the same Eden AI key: pin one with its endpoint ID, or let Eden AI route for you.

Endpoint
Region
Context
Input / 1M
Output / 1M
Cached / 1M
Supports
Qwenqwen/glm-5.1
Global
203K
$1.40$0.91
$2.86
$0.169
−35% · Reasoning · Tools · JSON · Cache
DeepInfra (United States)deepinfra/zai-org/GLM-5.1
United States
203K
$1.05
$3.5
$0.205
Reasoning · Tools · JSON · Cache
TensorX (Europe)tensorx/z-ai/glm-5.1
Europe
203K
$1.4
$4.4
$0.35
Reasoning · Tools · JSON · Cache
Z.ai (Asia)zai/glm-5.1
Asia
203K
$1.4
$4.4
$0.26
Official · Reasoning · Tools · Cache

Performance

Measured on real Eden AI traffic over the last 30 days. Endpoints with too little traffic are not shown.

Fastest first token
0.42 s
TensorX (Europe)
Lowest latency
1.31 s
TensorX (Europe)
Highest throughput
54.48 tok/s
TensorX (Europe)
Best availability
100%
TensorX (Europe)
Endpoint
First token
Latency p50
Latency p95
Throughput
Availability
Cache hits
Tool errors
JSON errors
Qwen
4.02 s
5.36 s
15.48 s
22.74 tok/s
100%
96.08%
29.3%
0%
DeepInfra (United States)
3.24 s
5.67 s
133.27 s
29.16 tok/s
100%
89.36%
0%
0%
TensorX (Europe)
0.42 s
1.31 s
6.67 s
54.48 tok/s
100%
25.36%
0%
0%
Z.ai (Asia)
3.67 s
3.8 s
18.36 s
14.4 tok/s
100%
77.53%
0%
0%

Estimate your monthly cost

Enter your expected volume to compare every endpoint at once.

Call GLM-5.1 with Eden AI

Use the model ID to let Eden AI pick an endpoint, or an endpoint ID from the table above to pin one.

import requests

response = requests.post(
    "https://api.edenai.run/v3/chat/completions",
    headers={"Authorization": "Bearer YOUR_EDENAI_API_KEY"},
    json={
        "model": "glm-5.1",
        "messages": [{"role": "user", "content": "Hello!"}],
    },
)
print(response.json())

Questions about GLM-5.1

On Eden AI, prices for this model start at $0.91 per million input tokens and $2.86 per million output tokens. Prices differ by endpoint; the providers table lists each one.

Up to 203K tokens, depending on the endpoint.

4 endpoints from 4 providers, available in: Global, Asia, Europe, United States. All of them are called with the same Eden AI API key.

Can I run GLM-5.1 in the EU? Yes. At least one endpoint is hosted in Europe; pin it with its endpoint ID from the providers table to keep requests in the EU. ‖ How fast is GLM-5.1? Over the last 30 days, the fastest first token was 0.42 s (TensorX (Europe)) and the highest throughput was 54.48 tokens per second (TensorX (Europe)).