Z.AI: GLM-5.1

stable

GLM-5.1 is available through Everstack's OpenAI-compatible gateway with routing, fallback, retries, and observability.

glm-5.1glmreleased Apr 7, 2026
Context
200K
tokens
Max output
131.1K
tokens
Input
$1.40
per 1M
Output
$4.40
per 1M

Activity

Daily period usage
Aggregated managed Everstack traffic. Buckets below 5 tenants or 100 requests are withheld.

Providers

Pricing

ItemPriceUnit
Input$1.40per 1M tokens
Output$4.40per 1M tokens
Cache read$0.26per 1M tokens
Cache write-per 1M tokens

Performance

Reliability

Compare

Compare usage and performance
Place this model beside up to three other catalog models.

Capabilities

Capabilities
Modalities
Input
Output
Details
Model ID
glm-5.1
Family
glm
Status
stable
Knowledge
-
Released
Apr 7, 2026
Gateway Config
API
2024-01-01
Auth
ZHIPU_API_KEY
Discovery
static
Provider type
static

Quick Start

index.ts
import Everstack from "@everstack/node";const client = new Everstack({  apiKey: process.env.EVERSTACK_API_KEY!,  baseUrl: "https://{instance}.{region}.everstack.ai",});const completion = await client.chat.completions.create({  model: "@zai/glm-5.1",  messages: [{ role: "user", content: "Explain vector cache routing." }],});console.log(completion.choices[0]?.message?.content);

Endpoint

Base URL
https://api.z.ai/api/paas/v4
Chat completions
https://api.z.ai/api/paas/v4/chat/completions
Model
glm-5.1
Auth env
ZHIPU_API_KEY

GLM-5.1 FAQ

How much does the GLM-5.1 API cost?

Through Z.AI, GLM-5.1 costs $1.40 per 1M input tokens and $4.40 per 1M output tokens. The lowest input price in the catalog is $1.00 per 1M tokens on Hugging Face.

What is the context window of GLM-5.1?

GLM-5.1 accepts up to 200K tokens of context and returns up to 131.1K output tokens on Z.AI.

Which providers offer GLM-5.1?

GLM-5.1 is available from Hugging Face, Fireworks AI, Together AI and Z.AI. Everstack can route between them with automatic fallback when one is unavailable.

What can GLM-5.1 do?

GLM-5.1 supports chat, function calling and reasoning. It accepts text input.

How do I call GLM-5.1 through Everstack?

Point any OpenAI-compatible SDK at your Everstack gateway and set the model to @zai/glm-5.1. Everstack adds retries, provider fallback, caching, per-tenant budgets and OpenTelemetry traces for every request.