---
title: Z.ai: GLM 4.7 Flash API | Text Generation | ModelsLab
description: 30B MoE LLM with 3.6B active params, 200K context; tops SWE-Bench/GPQA for coding, reasoning, agents; runs on 24GB VRAM.[1][3][2]
url: https://modelslab.com/models/z-ai/z-ai-glm-4.7-flash.md
canonical: https://modelslab.com/models/z-ai/z-ai-glm-4.7-flash.md
type: product
component: Playground/LLM/Index
generated_at: 2026-04-15T00:21:06.136366Z
---

Z.ai: GLM 4.7 Flash
---

 [LLMs.txt](https://modelslab.com/models/open_router/z-ai-glm-4.7-flash/llms.txt) [.md](https://modelslab.com/models/z-ai/z-ai-glm-4.7-flash.md)

z-ai-glm-4.7-flash z-ai Closed Source Model $0.230000 / call

Z.ai: GLM 4.7 Flash
---

Choose a prompt below to get started or type your own message

 Explain quantum computing in simple terms

 Write a Python function to sort a list

 Create a marketing email for a SaaS product

 Compare REST vs GraphQL APIs

Send

### Z.ai: GLM 4.7 Flash

z-ai z-ai-glm-4.7-flash

Copy model ID

PricingInput $0.06 / 1M tokens

Output $0.40 / 1M tokens

API EndpointsOpenAI Compatible

`https://modelslab.com/api/v7/llm/chat/completions`Endpoint

Anthropic Compatible

`https://modelslab.com/api/v7/llm/v1/messages`Messages

`https://modelslab.com/api/v7/llm/v1/messages/count_tokens`Count Tokens

`https://modelslab.com/api/v7/llm/v1/models`Models

Use with Claude Code

cURL Example

ParametersSystem MessageYou are a helpful AI assistant specialized in providing accurate and detailed responses.

Temperature0.7

Max Tokens1000

Top P0.9

Frequency Penalty0

Presence Penalty0

Model Info

Support

Related Models
---

Discover similar models you might be interested in

 [View all LLM Models](https://modelslab.com/models?feature=llmaster)

[LL](https://modelslab.com/models/open_router/liquid-lfm-2.5-1.2b-thinking-free)[Open Router](https://modelslab.com/models/open_router)

 [LiquidAI: LFM2.5-1.2B-Thinking (free)

Closed Source Model](https://modelslab.com/models/open_router/liquid-lfm-2.5-1.2b-thinking-free)

[OG](https://modelslab.com/models/open_router/openai-gpt-5.2-chat)[Open Router](https://modelslab.com/models/open_router)

 [OpenAI: GPT-5.2 Chat

Closed Source Model](https://modelslab.com/models/open_router/openai-gpt-5.2-chat)

[QQ](https://modelslab.com/models/open_router/qwen-qwen3.5-35b-a3b)[Open Router](https://modelslab.com/models/open_router)

 [Qwen: Qwen3.5-35B-A3B

Closed Source Model](https://modelslab.com/models/open_router/qwen-qwen3.5-35b-a3b)

[QQ](https://modelslab.com/models/open_router/qwen-qwen3-vl-235b-a22b-instruct)[Open Router](https://modelslab.com/models/open_router)

 [Qwen: Qwen3 VL 235B A22B Instruct

Closed Source Model](https://modelslab.com/models/open_router/qwen-qwen3-vl-235b-a22b-instruct)

[SL](https://modelslab.com/models/open_router/sao10k-l3.3-euryale-70b)[Open Router](https://modelslab.com/models/open_router)

 [Sao10K: Llama 3.3 Euryale 70B

Closed Source Model](https://modelslab.com/models/open_router/sao10k-l3.3-euryale-70b)

[G4](https://modelslab.com/models/together_ai/zai-org-GLM-4.6)[Together AI](https://modelslab.com/models/together_ai)

 [GLM 4.6 Fp8

Closed Source Model](https://modelslab.com/models/together_ai/zai-org-GLM-4.6)

[MM](https://modelslab.com/models/together_ai/MiniMaxAI-MiniMax-M2)[Together AI](https://modelslab.com/models/together_ai)

 [MiniMax M2

Closed Source Model](https://modelslab.com/models/together_ai/MiniMaxAI-MiniMax-M2)

[L4](https://modelslab.com/models/together_ai/meta-llama-Llama-4-Maverick-17B-128E)[Together AI](https://modelslab.com/models/together_ai)

 [Llama 4 Maverick 17B 128E

Closed Source Model](https://modelslab.com/models/together_ai/meta-llama-Llama-4-Maverick-17B-128E)

[M(](https://modelslab.com/models/mistral_ai/mistralai-Mistral-7B-Instruct-v0.3)[ModelsLab](https://modelslab.com/models/mistral_ai)

 [Mistral (7B) Instruct v0.3

Closed Source Model](https://modelslab.com/models/mistral_ai/mistralai-Mistral-7B-Instruct-v0.3)

[NH](https://modelslab.com/models/open_router/nousresearch-hermes-3-llama-3.1-405b-free)[Open Router](https://modelslab.com/models/open_router)

 [Nous: Hermes 3 405B Instruct (free)

Closed Source Model](https://modelslab.com/models/open_router/nousresearch-hermes-3-llama-3.1-405b-free)

[Q7](https://modelslab.com/models/together_ai/Qwen-Qwen2.5-7B-Instruct)[Together AI](https://modelslab.com/models/together_ai)

 [Qwen2.5 7B Instruct

Closed Source Model](https://modelslab.com/models/together_ai/Qwen-Qwen2.5-7B-Instruct)

[G5](https://modelslab.com/models/together_ai/zai-org-GLM-5.1)[Together AI](https://modelslab.com/models/together_ai)

 [GLM 5.1 FP4

Closed Source Model](https://modelslab.com/models/together_ai/zai-org-GLM-5.1)

[ML](https://modelslab.com/models/together_ai/meta-llama-Meta-Llama-3.1-70B-Instruct-Turbo)[Together AI](https://modelslab.com/models/together_ai)

 [Meta Llama 3.1 70B Instruct Turbo

Closed Source Model](https://modelslab.com/models/together_ai/meta-llama-Meta-Llama-3.1-70B-Instruct-Turbo)

[KK](https://modelslab.com/models/open_router/kwaipilot-kat-coder-pro-v2)[Open Router](https://modelslab.com/models/open_router)

 [Kwaipilot: KAT-Coder-Pro V2

Closed Source Model](https://modelslab.com/models/open_router/kwaipilot-kat-coder-pro-v2)

[GG](https://modelslab.com/models/open_router/google-gemma-3-27b-it-free)[Open Router](https://modelslab.com/models/open_router)

 [Google: Gemma 3 27B (free)

Closed Source Model](https://modelslab.com/models/open_router/google-gemma-3-27b-it-free)

[BS](https://modelslab.com/models/open_router/bytedance-seed-seed-1.6-flash)[Open Router](https://modelslab.com/models/open_router)

 [ByteDance Seed: Seed 1.6 Flash

Closed Source Model](https://modelslab.com/models/open_router/bytedance-seed-seed-1.6-flash)

[CV](https://modelslab.com/models/together_ai/deepcogito-cogito-v1-preview-qwen-14B)[Together AI](https://modelslab.com/models/together_ai)

 [Cogito V1 Preview Qwen 14B

Closed Source Model](https://modelslab.com/models/together_ai/deepcogito-cogito-v1-preview-qwen-14B)

[OG](https://modelslab.com/models/open_router/openai-gpt-4-turbo)[Open Router](https://modelslab.com/models/open_router)

 [OpenAI: GPT-4 Turbo

Closed Source Model](https://modelslab.com/models/open_router/openai-gpt-4-turbo)

About Z.Ai: GLM 4.7 Flash
---

As a 30B-class SOTA model, GLM-4.7-Flash offers a new option that balances performance and efficiency. It is further optimized for agentic coding use cases, strengthening coding capabilities, long-horizon task planning,...

### Technical Specifications

Model IDz-ai-glm-4.7-flashCategoryLLM ModelsTaskText GenerationPrice$0.230000 per million tokensAddedFebruary 20, 2026

### Key Features

- Chat completion and multi-turn conversation API
- Streaming response with token-by-token output
- Function calling and tool use support
- System prompts and role-based messaging
- JSON mode and structured output

### Quick Start

Integrate Z.Ai: GLM 4.7 Flash into your application with a single API call. Get your API key from the [pricing page](https://modelslab.com/pricing) to get started.

PythonJavaScriptcURLPHP

```
<code>import requests
import json

url = "https://modelslab.com/api/v7/llm/chat/completions"

headers = {
    "Content-Type": "application/json"
}

data = {
        "model_id": "z-ai-glm-4.7-flash",
        "messages": [
            {
                "role": "user",
                "content": "Hello!"
            }
        ],
        "max_tokens": 1000,
        "key": "YOUR_API_KEY"
    }

try:
    response = requests.post(url, headers=headers, json=data)
    response.raise_for_status()  # Raises an HTTPError for bad responses (4XX or 5XX)
    result = response.json()
    print("API Response:")
    print(json.dumps(result, indent=2))
except requests.exceptions.HTTPError as http_err:
    print(f"HTTP error occurred: {http_err} - {response.text}")
except Exception as err:
    print(f"Other error occurred: {err}")</code>
```

View the [full API documentation](https://modelslab.com/models/z-ai/z-ai-glm-4.7-flash/api) for SDKs, code examples in Python, JavaScript, and more.

### Pricing

Z.Ai: GLM 4.7 Flash API costs $0.230000 per million tokens. Pay only for what you use with no minimum commitments. [View pricing plans](https://modelslab.com/pricing)

### Use Cases

- AI chatbots and virtual assistants
- Code generation and developer tools
- Content writing and copywriting automation
- Data analysis, summarization, and extraction

[Browse LLM Models](https://modelslab.com/models?feature=llmaster) [More from Z Ai](https://modelslab.com/models/open_router) [View Pricing](https://modelslab.com/pricing)

Z.Ai: GLM 4.7 Flash FAQ
---

### What is Z.Ai: GLM 4.7 Flash?

As a 30B-class SOTA model, GLM-4.7-Flash offers a new option that balances performance and efficiency. It is further optimized for agentic coding use cases, strengthening coding capabilities, long-horizon task planning,...

### How do I use the Z.Ai: GLM 4.7 Flash API?

You can integrate Z.Ai: GLM 4.7 Flash into your application with a single API call. Sign up on ModelsLab to get your API key, then use the model ID "z-ai-glm-4.7-flash" in your API requests. We provide SDKs for Python, JavaScript, and cURL examples in the API documentation.

### How much does Z.Ai: GLM 4.7 Flash cost?

Z.Ai: GLM 4.7 Flash costs $0.230000 per million tokens. ModelsLab uses pay-per-use pricing with no minimum commitments. A free tier is available to get started.

### What is the Z.Ai: GLM 4.7 Flash model ID?

The model ID for Z.Ai: GLM 4.7 Flash is "z-ai-glm-4.7-flash". Use this ID in your API requests to specify this model.

### Does Z.Ai: GLM 4.7 Flash have a free tier?

Yes, ModelsLab offers a free tier that lets you try Z.Ai: GLM 4.7 Flash and other AI models. Sign up to get free API credits and start building immediately.

---

*This markdown version is optimized for AI agents and LLMs.*

**Links:**
- [Website](https://modelslab.com)
- [API Documentation](https://docs.modelslab.com)
- [Blog](https://modelslab.com/blog)

---
*Generated by ModelsLab - 2026-04-15*