GLM 4.7 API Pricing
As of October 10, 2026, GLM 4.7 costs $0.60 per 1M input tokens and $2.20 per 1M output tokens on Z.ai, with cache reads at $0.11 and cache writes at $0 per 1M tokens. Across 9 providers on LiteLLM, the input price ranges from $0.40 to $0.60. It has a 200,000-token context window and returns up to 128,000 tokens per response.
- Input
- $0.60 / 1M tokens
- Output
- $2.20 / 1M tokens
- Cache read
- $0.11 / 1M tokens
- Context window
- 200,000 tokens
- Max output
- 128,000 tokens
- Providers
- 9
- Added to LiteLLM
- January 2026
GLM 4.7 pricing by provider
10 listings across 9 providers. Token prices are in US dollars per 1M tokens. The highlighted row is the price quoted above.
| Provider | Model name in LiteLLM | Input | Output | Cache read | Cache write | Context |
|---|---|---|---|---|---|---|
| Z.ai | zai/glm-4.7 | $0.60 | $2.20 | $0.11 | $0 | 200K |
| Amazon Bedrock | zai.glm-4.7 | $0.60 | $2.20 | – | – | 203K |
| Baseten | baseten/zai-org/GLM-4.7 | $0.60 | $2.20 | $0.12 | – | 200K |
| DeepInfra | deepinfra/zai-org/GLM-4.7 | $0.40 | $1.75 | $0.08 | – | 198K |
| Fireworks AI | fireworks_ai/accounts/fireworks/models/glm-4p7 | $0.60 | $2.20 | $0.30 | – | 203K |
| Fireworks AI | fireworks_ai/glm-4p7 | $0.60 | $2.20 | $0.30 | – | 203K |
| Google Vertex AI | vertex_ai/zai-org/glm-4.7-maas | $0.60 | $2.20 | $0.06 | – | 200K |
| Novita AI | novita/zai-org/glm-4.7 | $0.60 | $2.20 | $0.11 | – | 200K |
| Together AI | together_ai/zai-org/GLM-4.7 | $0.45 | $2.00 | – | – | 198K |
| GMI Cloudfp8 | gmi/zai-org/GLM-4.7-FP8 | $0.40 | $2.00 | – | – | 198K |
What GLM 4.7 costs in practice
1,000 requests with 2,000 input and 500 output tokens each
| Z.ai | $2.30 |
| DeepInfra | $1.675 |
| Together AI | $1.90 |
| Amazon Bedrock | $2.30 |
100 long-document requests with 100,000 input and 2,000 output tokens each
| Z.ai | $6.44 |
| DeepInfra | $4.35 |
| Together AI | $4.90 |
| Amazon Bedrock | $6.44 |
GLM 4.7 features
- Function calling
- Parallel tool calls
- Structured output
- Reasoning
- Prompt caching
Use GLM 4.7 with LiteLLM
Call GLM 4.7 through the LiteLLM Python SDK, or put it behind the LiteLLM proxy and send OpenAI-format requests to /v1/chat/completions. LiteLLM tracks the cost of every request at these prices.
from litellm import completion
response = completion(
model="zai/glm-4.7",
messages=[{"role": "user", "content": "Hello!"}],
)model_list:
- model_name: glm-4.7
litellm_params:
model: zai/glm-4.7
# credentials: see the provider's LiteLLM docs pagecurl http://0.0.0.0:4000/v1/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer sk-1234" \
-d '{
"model": "glm-4.7",
"messages": [{"role": "user", "content": "Hello!"}]
}'GLM 4.7 FAQ
How much does GLM 4.7 cost?
GLM 4.7 costs $0.60 per 1M input tokens and $2.20 per 1M output tokens on Z.ai, with cache reads at $0.11 and cache writes at $0 per 1M tokens. Across 9 providers on LiteLLM, the input price ranges from $0.40 to $0.60.
What is the context window of GLM 4.7?
GLM 4.7 has a 200,000-token context window and returns up to 128,000 tokens per response.
Which providers offer GLM 4.7?
GLM 4.7 is available from 9 providers through LiteLLM: Z.ai, Amazon Bedrock, Baseten, DeepInfra, Fireworks AI, Google Vertex AI, Novita AI, Together AI and GMI Cloud. The lowest price is on DeepInfra.
How do I call GLM 4.7 with an OpenAI-compatible API?
Use the LiteLLM Python SDK with model="zai/glm-4.7", or add the model to the LiteLLM proxy's config.yaml and send requests to /v1/chat/completions from any OpenAI client. LiteLLM tracks the cost of every request at the prices on this page.
What features does GLM 4.7 support?
GLM 4.7 supports function calling, parallel tool calls, structured output, reasoning and prompt caching.
When did LiteLLM add GLM 4.7?
GLM 4.7 was added to LiteLLM's model price file in January 2026.
Sources
Prices come from LiteLLM's open-source model_prices_and_context_window.json, which LiteLLM uses to calculate the cost of every request. Provider pricing pages:
- docs.z.ai/guides/overview/pricing
- docs.aws.amazon.com/bedrock/latest/userguide/model-card-zai-glm-4-7.html
- inference.baseten.co/v1/models
- deepinfra.com/pricing
LiteLLM docs: Z.ai, Amazon Bedrock, Baseten, DeepInfra, Fireworks AI, Google Vertex AI.
Provider pages: Z.ai, Amazon Bedrock, Baseten, DeepInfra, Fireworks AI, Google Vertex AI, Novita AI, Together AI, GMI Cloud.
