4 個模型 · chat / code / reasoning / tools · 輸入價低至 $1/M
為什麼透過 Synthorai 使用 Z.ai
- 按用量計費,無需訂閱。 一組 key 用遍所有模型,無需 Z.ai 帳號。
- 零提示詞留存。 閘道器預設零提示詞留存;上游適用 Z.ai 自身的 API 資料政策。 詳情 →
- 提示詞快取。 自動提示詞快取:重複的提示詞前綴按價格表所示的快取命中費率計費,無需改程式碼。 快取讀取低至 $0.2/M。
Z.ai 模型與價格
| 模型 | 輸入 /M | 輸出 /M | 快取讀取 /M | 上下文 |
|---|---|---|---|---|
| GLM-5.1 | $1.4 | $4.4 | $0.26 | 200K |
| GLM-5.2 | $1.4 | $4.4 | $0.26 | 1M |
| GLM-5-Turbo | $1.2 | $4 | $0.24 | 205K |
| GLM-5 | $1 | $3.2 | $0.2 | 200K |
廠商牌價,無平台加價。各模型頁面的價格即時更新。 以下為官方 list 價。已登入的使用者可在 /console/pricing 查看含工作空間折扣的實際價格。
30 秒用上 Z.ai 模型
from openai import OpenAI
client = OpenAI(
base_url="https://synthorai.io/v1",
api_key="sk-syn-...",
)
resp = client.chat.completions.create(
model="glm-5.1",
messages=[{"role": "user", "content": "Summarize this diff"}],
reasoning_effort="medium",
)
print(resp.choices[0].message.content)import OpenAI from "openai";
const client = new OpenAI({
baseURL: "https://synthorai.io/v1",
apiKey: "sk-syn-...",
});
const resp = await client.chat.completions.create({
model: "glm-5.1",
messages: [{ role: "user", content: "Summarize this diff" }],
reasoning_effort: "medium",
});
console.log(resp.choices[0].message.content);curl https://synthorai.io/v1/chat/completions \
-H "Authorization: Bearer sk-syn-..." \
-H "Content-Type: application/json" \
-d '{
"model": "glm-5.1",
"messages": [{"role": "user", "content": "Hello"}],
"reasoning_effort": "medium"
}'package main
import (
"context"
"fmt"
"github.com/openai/openai-go/v3"
"github.com/openai/openai-go/v3/option"
)
func main() {
client := openai.NewClient(
option.WithBaseURL("https://synthorai.io/v1"),
option.WithAPIKey("sk-syn-..."),
)
resp, _ := client.Chat.Completions.New(context.TODO(), openai.ChatCompletionNewParams{
Model: "glm-5.1",
Messages: []openai.ChatCompletionMessageParamUnion{
openai.UserMessage("Summarize this diff"),
},
ReasoningEffort: openai.ReasoningEffortMedium,
})
fmt.Println(resp.Choices[0].Message.Content)
}import com.openai.client.OpenAIClient;
import com.openai.client.okhttp.OpenAIOkHttpClient;
import com.openai.models.chat.completions.*;
import com.openai.models.ReasoningEffort;
OpenAIClient client = OpenAIOkHttpClient.builder()
.baseUrl("https://synthorai.io/v1")
.apiKey("sk-syn-...")
.build();
ChatCompletion resp = client.chat().completions().create(
ChatCompletionCreateParams.builder()
.model("glm-5.1")
.addUserMessage("Summarize this diff")
.reasoningEffort(ReasoningEffort.MEDIUM)
.build());
System.out.println(resp.choices().get(0).message().content().orElse(""));關於 Z.ai
Z.ai(前身為智譜)打造 GLM 家族:編碼與智慧體效能突出、價格激進的前沿開源權重模型;GLM-5.2 是閘道器上價效比最高的選擇之一。Synthorai 透過與其他所有模型相同的 OpenAI 相容端點提供 GLM,價格即時更新,支援處按提示詞快取讀取計費。
常見問題
不用訂閱要怎麼取得 Z.ai API key?
不需要 Z.ai 帳號:註冊 Synthorai,建立一組 API key,本頁所有 Z.ai 模型都能透過 OpenAI 相容端點呼叫,按用量計費,無需訂閱(標示「邀請制測試」的模型另需申請通過)。
Z.ai API 的價格是多少?
按 token 計費的模型輸入價低至 $1/M;每個模型的即時單價見上表,皆為廠商牌價,無平台加價。
可以使用自己的 Z.ai 金鑰(BYOK)嗎?
Z.ai 的 BYOK 暫未開放,請求經 Synthorai 的託管通道按所列費率執行。
Z.ai 的 API 資料留存政策是什麼?
閘道器預設零提示詞留存;上游適用 Z.ai 自身的 API 資料政策。