zai-glm-4.7 — Free API

⭐ Score: 58
cerebras/zai-glm-4-7
chat

What is zai-glm-4.7?

GLM-4.7 is Z.AI's (Zhipu AI) latest-generation bilingual model, offered free through Cerebras Cloud on its WSE inference hardware. With 128K context, OpenAI-compatible API, and no credit card requirement, it is a strong choice for developers who need Chinese-English bilingual performance or want an alternative to the Llama/Qwen families. The free tier is more constrained than some Cerebras endpoints — 100 requests per day at 10 RPM with a 1M token daily cap — so it is best used for evaluation, comparison testing, or low-volume bilingual tasks rather than continuous production traffic.

Model ID
zai-glm-4-7
Base URL
https://api.cerebras.ai/v1

zai-glm-4.7 API Code Example

Paste your API key and run. See the config generator for Claude Code, Cursor, and more tools.

from openai import OpenAI

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

response = client.chat.completions.create(
    model="zai-glm-4-7",
    messages=[{"role": "user", "content": "Hello!"}]
)
print(response.choices[0].message.content)
import OpenAI from "openai";

const openai = new OpenAI({
  baseURL: "https://api.cerebras.ai/v1",
  apiKey: "YOUR_API_KEY",
});

const completion = await openai.chat.completions.create({
  model: "zai-glm-4-7",
  messages: [{ role: "user", content: "Hello!" }],
});

console.log(completion.choices[0].message.content);
curl https://api.cerebras.ai/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
    "model": "zai-glm-4-7",
    "messages": [{"role": "user", "content": "Hello!"}]
  }'

Other Free Models from Cerebras

More About Cerebras

How to get an API key, rate limits, platform limitations, and tool configuration — everything you need to set up Cerebras as a free LLM API backend.

View Cerebras full guide →