GLM 5.3 API, OpenAI-compatible
Z.ai’s GLM 5.3 — the flagship agentic coding model of the GLM-5 series — pairs a 1,048,576-token context window with reasoning, function calling and structured outputs, at the same list price GLM-5.2 charges for a 262K window. Served on Cloudflare Workers AI infrastructure through one OpenAI-compatible endpoint: prepaid USD credits, per-token billing you can audit, and 40% off the list price for the launch period.
What you get
- Context window
- 1,048,576 tokens (input + max_tokens) — 4× GLM-5.2, confirmed against the endpoint’s own limit message
- Positioning (per Z.ai)
- Flagship agentic coding model — built for multi-step, tool-driven development workflows
- Image input
- No — our probe came back 0/2: the model accepts the image, then answers that it cannot see it. The gateway refuses image requests to this model by name before they cost you anything; four other catalog models do read images
- Function calling
- Yes — verified in our contract tests, tools called with correct schema
- Reasoning
- Yes — streamed as reasoning_content, billed once at output rate; effort levels none/low/medium/high/max (a different set from GLM 5.3 Flash — the gateway validates per model)
- JSON mode
- Yes — verified: response_format json_object returns valid JSON. Give it max_tokens headroom — the model reasons before it answers
- Cached input
- A published rate — our repeat-probes have not seen a hit on this model yet; see the caching note below
- Upstream ID (public)
- @cf/zai-org/glm-5.3
- Privacy
- Runs on Cloudflare infrastructure; we log metadata only — never prompt or response content
Pricing (40% off list, applied automatically)
- Input
$1.40$0.84- Output
$4.40$2.64
@cf/zai-org/glm-5.3
Struck price = list — and the list price is the same as GLM-5.2’s, with 4× the context window. The cached-input rate is published upstream, but our identical-repeat probes have not seen a cache hit on this model yet, so treat it as a bonus, not a budget line. Live prices for all nine models are on the models page, synced from the billing database that rates your requests.
Measured, not quoted
Our own measurements, 2026-08-28 — the day we added the model. Live status and per-model numbers stay on the models page.
~0.8 s
time to first token (p50, 5 streams, none hung)
~107 tok/s
streaming throughput (p50)
72–77 ms / 1K tokens
prefill rate measured at 50K–300K input
~23 s
first token on a real 300K-token prompt — use streaming for large jobs
Ship in two lines of config
If your code already talks to the OpenAI API, you only change base_url and the key. The model id is glm-5.3; the upstream id is public.
from openai import OpenAI
client = OpenAI(
base_url="https://api.clfaigateway.dev/v1",
api_key="sk-gw-...", # app.clfaigateway.dev
)
resp = client.chat.completions.create(
model="glm-5.3",
messages=[{"role": "user", "content": "Refactor this module..."}],
stream=True,
)
for chunk in resp:
print(chunk.choices[0].delta.content or "", end="")GLM 5.3 on the gateway — common questions
The window counts input plus your max_tokens budget. Prefill is real work at this size — we measured 72–77 ms per 1,000 input tokens from 50K up to 300K, so a 300K-token prompt takes about 23 seconds before the first token. Always stream large requests, and expect retryable capacity errors at peak times on very large prompts.
Context & caching docs →No — and we checked instead of assuming. Our standard probe sends two solid-colour images; GLM 5.3 answered 0/2, accepting each image and then saying it cannot see it. That silent failure mode is exactly why the gateway refuses image requests to this model up front with a named error, before they cost you anything. Four catalog models do read images, verified the same way.
Which models read images →Same 1M window, different trade. The full model is Z.ai’s flagship for coding and agentic work, and in our runs it streamed ~107 tokens/s with a 0.8 s first token; Flash is about 9× cheaper on input and reads images, at ~80 tok/s and a slower first token. One concrete API difference we hit: they accept different reasoning_effort sets — none/low/medium/high/max here, low/medium/high/xhigh on Flash. The gateway validates per model and names the valid levels in the error message.
GLM 5.3 Flash page →The upstream list price per million tokens is identical to GLM-5.2’s across all three dimensions — input, cached input and output — while the context window grows from 262,144 to 1,048,576 tokens. Both models carry the same 40% launch discount here, so picking GLM 5.3 costs nothing extra per token and quadruples the window.
Compare live prices →The rate is published upstream, but on this model our identical 300K-token repeat within a minute still billed zero cached tokens — we have not seen a hit here yet, and we publish that instead of promising savings. If upstream starts serving cache hits, the cached rate applies automatically and your usage log will show it.
How caching behaves →We added it the day it appeared and measured everything we publish — around fifty calls, none of which hit the transient upstream errors we saw on Flash’s first day. A good early sign, not a guarantee: the gateway still translates upstream hiccups into clean retryable errors and fails over where it can, and the status page will say so if reliability shifts.
Prepaid credits, billed per actual token from upstream usage — never estimates. Reasoning tokens are part of output and billed once. Every request shows its exact cost in your usage log, and the ledger adds up to the nano-dollar.
Billing docs →