GLM 4.5

Zhipu Ai chatreasoningtool_use

API ID: z-ai/glm-4.5

Input Price
$0.35
/1M tokens
Output Price
$1.55
/1M tokens

About GLM 4.5

GLM-4.5 is our latest flagship foundation model, purpose-built for agent-based applications. It leverages a Mixture-of-Experts (MoE) architecture and supports a context length of up to 128k tokens. GLM-4.5 delivers significantly enhanced capabilities in reasoning, code generation, and agent alignment. It supports a hybrid inference mode with two options, a "thinking mode" designed for complex reasoning and tool use, and a "non-thinking mode" optimized for instant responses. Users can control the reasoning behaviour with the `reasoning` `enabled` boolean. [Learn more in our docs](https://openrouter.ai/docs/use-cases/reasoning-tokens#enable-reasoning-with-default-config)

๐Ÿ’ฐ
Price Ranking
#920 lowest price among 1240 Chat models

Model Specifications

Context Length
131k
Max Output
98k
Release Date
2025-07-25
Capabilities
chat reasoning tool_use
Input Modalities
text
Output Modalities
text

Best For

  • Complex reasoning, math problems, multi-step logic
  • Conversations, content writing, general assistance

Consider Alternatives For

  • Image understanding (needs vision capability)
  • Simple Q&A (cheaper models available)

๐Ÿ’ฐ Real-World Cost Examples

Estimated monthly costs for common use cases

Personal AI Assistant
$0.62
/month
50 conversations/day, ~500 tokens each
Customer Service Bot
$19.20
/month
1000 tickets/day, ~800 tokens each
Data Analysis Pipeline
$26.48
/month
500 analyses/day, ~2k tokens each

Zhipu Ai Model Lineup

Compare all models from Zhipu Ai to find the best fit

Model Input Output Context Capabilities
GLM 4.5 Current Free Free 131k chat reasoning tool_use
GLM 4 9B Free Free 32k chat
GLM 4 9B Free Free 32k chat
GLM 4 32B Free Free 33k chat
GLM 4 32B Free Free 33k chat
GLM 4.1V 9B Thinking Free Free 66k chat vision reasoning

Similar Models from Other Providers

Cross-brand alternatives with similar capabilities

Google Gemini 3.1 Flash Lite
Input: $0.28
Output: $1.65
Context: 1.0M
Arcee Ai Virtuoso Large
Input: $0.75
Output: $1.20
Context: 131k
Alibaba Qwen Qwen3.5 Plus 2026-02-15
Input: $0.26
Output: $1.56
Context: 1.0M
Other Step3
Input: $0.57
Output: $1.42
Context: 66k

๐Ÿš€ Quick Start

Get started with GLM 4.5 API

OpenAI-compatible SDK
from openai import OpenAI

client = OpenAI(
    base_url="https://api.provider.com/v1",
    api_key="YOUR_API_KEY"
)

response = client.chat.completions.create(
    model="z-ai/glm-4.5",
    messages=[
        {"role": "user", "content": "Hello!"}
    ]
)
print(response.choices[0].message.content)