Skip to content

GLM-5.2 API Provider Comparison: Price, Limits and Privacy

Independent research — not an official Z.ai publication.Identity and provider disclosure

Decision map comparing Z.ai direct, Novita, OpenRouter, Coding Plan, and self-hosted GLM-5.2 by cost, provider control, privacy, and workload

Rates and policies checked July 17, 2026; Z.ai access routes rechecked July 20. Provider prices, routes, promotions, capacity and terms can change. Recheck the linked source before funding an account.

A useful GLM-5.2 API provider comparison starts after the price table. Two endpoints can advertise the same model and still differ in quantization, context, output cap, function behavior, data path, rate limit, observability and failure recovery. A gateway can also change the endpoint behind one model ID.

We compared three practical access routes with public evidence:

  • Z.ai direct API, the first-party endpoint;
  • Novita serverless API, a direct third-party FP8 host;
  • OpenRouter, a gateway that routes one model ID across many inference providers.

We did not send paid production traffic or run a controlled load test. Prices and product facts below come from provider documentation and public model APIs. Availability comments identify the source and do not claim an independent SLA test.

  1. Z.ai GLM-5.2 quick access
  2. Z.ai GLM-5.2 FAQ
  3. Recommendations by workload
  4. Price, context and output limits
  5. Function calling, structured output and MCP
  6. Regions and payment methods
  7. Rate limits and concurrency
  8. Logging, retention and privacy
  9. Availability and error-rate evidence
  10. Provider-by-provider verdict
  11. What we tested
  12. Affiliate disclosure
  13. Sources and update method

This section answers the navigational “Z.ai GLM-5.2” query without duplicating the broader provider, purchasing and local-deployment guides.

Task Correct route Important boundary
Try the hosted chat Open the official Z.ai chat and sign in A chat session is not API credit or proof of an application’s rate limit
Create or manage a key Open Z.ai API Keys Keep the key in ZAI_API_KEY; never paste it into a repository or browser bundle
Call the metered API Base URL https://api.z.ai/api/paas/v4; model ID glm-5.2 Token billing applies; use this route for a website, service or automation
Use a Coding Plan key Base URL https://api.z.ai/api/coding/paas/v4 The subscription quota is for supported coding clients, not a general SaaS backend
Compare current list rates $1.40/M input, $0.26/M cached input and $4.40/M output in our July 17 first-party snapshot Prices, cache rules and availability can change; verify before purchase
Run the open weights Download zai-org/GLM-5.2 and follow the local hardware guide Local deployment needs datacenter-class storage, memory and serving software

The general chat-completions request path is https://api.z.ai/api/paas/v4/chat/completions. Z.ai documents Bearer authentication, so a minimal shell environment starts with export ZAI_API_KEY="...". Do not swap only the base URL and assume the same key, quota and use policy apply: the general API and Coding Plan are different products.

For OpenCode specifically, use the copyable GLM-5.2 OpenCode configuration, including its post-configuration tool-call test. To choose between the subscription, metered API and your own GPUs, use the workload-based access guide. The rest of this page compares provider-level price, limits, privacy and operations.

Use Z.ai Chat for a manual chat session. Developers should sign in to the API-key console instead. A chat account, Coding Plan subscription and metered API balance are related Z.ai products, not one interchangeable quota.

What endpoint and model ID does the API use?

Section titled “What endpoint and model ID does the API use?”

The general pay-as-you-go base URL is https://api.z.ai/api/paas/v4, the chat-completions path is /chat/completions, and the documented model ID is glm-5.2. Coding Plan clients use https://api.z.ai/api/coding/paas/v4. Put the secret in ZAI_API_KEY and send it as a Bearer token.

Is the Coding Plan the same as normal API billing?

Section titled “Is the Coding Plan the same as normal API billing?”

No. The Coding Plan is a subscription with rolling and weekly quotas for supported coding clients. The general API bills application traffic by token. Confirm the endpoint and account product before debugging a 401 or unexpected balance charge.

Can I deploy GLM-5.2 locally instead of using Z.ai?

Section titled “Can I deploy GLM-5.2 locally instead of using Z.ai?”

Yes. Z.ai publishes the weights under MIT through zai-org/GLM-5.2, but the full checkpoint is a datacenter-class deployment. Use the GLM-5.2 local hardware and serving guide to size storage, accelerator memory, KV cache and runtime headroom.

OpenRouter’s balanced GLM-5.2 catalog route had the lowest published token snapshot in this review: about $0.9478/M input, $0.17602/M cached input and $2.9788/M output before its 5.5% pay-as-you-go credit-purchase fee. The route can select a changing provider. The cheapest endpoint may use FP4 rather than Z.ai’s official FP8 checkpoint, and endpoint support can change.

Choose it for cost-sensitive work only after you pin the provider or accept routing changes, record the returned provider, and run your own acceptance set. A lower list price has little value if a tool loop needs more retries.

Use the GLM-5.2 cost calculator with your input, output, cache and retry mix. Output-heavy agents can produce a different winner from short classification calls.

Z.ai direct and Novita publish the cleanest full-capability contract: 1,048,576 total context tokens and up to 131,072 output tokens. Novita identifies the hosted checkpoint as FP8. Z.ai publishes the same limits in its model guide.

OpenRouter’s model record also lists a 1,048,576-token context and a 131,072-token top-provider output cap, but individual routes vary. Its public endpoint catalog included 101,376-, 131,072- and 262,144-context routes alongside one-million-token routes when we checked. Send require_parameters, constrain provider order, and inspect the selected endpoint if the full window is a requirement.

Apply the GLM-5.2 max-tokens and context budget before sending a long request; total context and output allowance are separate limits, and the selected route or client can lower either one.

Do not reserve one million tokens by habit. Long prompts raise prefill latency, cache pressure and the cost of a failed retry. Start at 32K or 128K and expand when evaluation shows a real gain.

Choose GLM Coding Plan for regular interactive use in a supported coding tool. It starts at $18 per month, uses a dedicated coding endpoint, and has rolling and weekly quotas. It is not general-purpose API credit and does not fit a website backend.

Start with the data flow, not a privacy badge.

  1. Self-hosting gives your team the most control over prompts, logs, keys and network boundaries, but only when your own infrastructure and operations meet the same standard.
  2. Z.ai’s API DPA says business API content is processed in real time and not saved, and customer data is generally processed in Singapore.
  3. Novita’s terms say it does not log, store or retain API user content without prior written consent.
  4. OpenRouter says it does not store prompts or responses by default, stores request metadata, offers per-request Zero Data Retention routing, and provides EU in-region routing to approved enterprise customers. The selected inference provider remains another processor.

These are contractual or policy statements, not our security audit. Ask for the DPA, subprocessor list, incident terms, deletion process, data region, support access rules and an SLA before sending regulated or confidential data.

Choose OpenRouter when one API key, automatic fallback and model switching reduce setup time. Choose Novita when you want a single FP8 route, OpenAI compatibility and a direct move from playground to API. Both paths reduce initial infrastructure work.

Prototype with a pinned prompt set. Record provider, latency, output tokens, cache tokens, tool-call validity, 429s and 5xx responses. A demo that succeeds once does not establish production fitness.

There is no universal production winner.

  • Choose Z.ai direct to minimize routing layers and stay closest to the publisher’s documented model behavior.
  • Choose Novita when its console metrics, account support and direct FP8 endpoint fit your operating model.
  • Choose OpenRouter when multi-provider fallback, spend controls, provider policy filters and routing telemetry matter more than a single fixed backend.

For all three, pin model IDs when possible, cap retries, apply exponential backoff with jitter, set a cost budget, validate every structured response, and keep a second model or provider behind a circuit breaker.

Choose self-hosting for a fixed checkpoint, private network, custom runtime, fine-tuning path or sustained utilization that can justify a datacenter-class node. The official FP8 artifact is about 756 GB. The official vLLM recipe fits it on 8×H200 with a 131,072-token serving limit; the full one-million-token recipe targets 8×B200.

Read the local hardware guide before renting hardware. A successful model load does not prove throughput, latency, tool-call quality or a lower total cost.

All prices below use USD per one million tokens. “Cached input” means cache-read tokens that meet the provider’s cache rules; it is not a discount applied to any repeated text.

Route Input Cached input Output Context Max output Price evidence
Z.ai direct $1.40 $0.26 $4.40 1,048,576 131,072 First-party pricing and model guide
Novita serverless $1.40 $0.26 $4.40 1,048,576 131,072 Novita model page, FP8
OpenRouter balanced route $0.9478 $0.17602 $2.9788 Up to 1,048,576 Route-dependent; catalog top is 131,072 Dynamic public model API snapshot

OpenRouter charges a 5.5% fee when pay-as-you-go users buy credits. Its token catalog price and funded cash cost are therefore different numbers. Taxes, currency conversion and enterprise terms can add another difference.

Z.ai and Novita have identical list rates in this snapshot, so their cost rows match for the same billed token counts. Their operational contract does not match. Compare data handling, limits, observability, support and failure behavior before treating them as interchangeable.

Function calling, structured output and MCP

Section titled “Function calling, structured output and MCP”
Route Function calling Structured output MCP reality
Z.ai direct Documented for GLM-5.2 JSON output documented Z.ai lists MCP integration; an MCP host still connects tools and returns results to the model
Novita Model page says supported JSON object supported; Novita’s FAQ says strict json_schema is not available No model-specific managed MCP promise found; use your client or agent framework
OpenRouter Supported parameters include tools and tool_choice Route-dependent; use require_parameters when required Gateway transports tool calls; your MCP client or tool layer owns MCP execution

Function calling is not function execution. Your application must validate arguments, enforce permissions, call the tool, handle timeouts and return the result. Structured output is also not proof that every response matches your business schema. Parse it, validate it and retry only the failed step.

The term MCP support causes confusion. GLM-5.2 can choose tools. MCP standardizes how a host discovers and calls external tools. A provider may supply built-in MCP services, or your coding agent may supply the MCP host. Ask which layer owns authentication, tool logs, consent and network access.

Route Processing region evidence Public payment evidence Purchase caution
Z.ai direct API DPA says customer data is generally processed in Singapore Checkout uses account billing; public campaign rules reference Stripe Card and country eligibility are not fully listed on the public docs we found; verify at checkout
Novita No region selector for the shared GLM-5.2 serverless API found Stripe; manual top-up minimum is $10 Dedicated GPU regions do not prove serverless inference region
OpenRouter Underlying provider varies; enterprise EU endpoint is available by request Major cards, AliPay and USDC Credit-purchase fee is 5.5%; EU routing has a distinct model list

If residency is a hard requirement, “global API” is not enough. Obtain the contracted region and the subprocessor path in writing. A gateway’s company address does not reveal where the selected model processed the prompt.

None of the three routes publishes one simple GLM-5.2 number that every account receives.

  • Z.ai direct: we did not find a public fixed GLM-5.2 RPM/TPM table. Confirm the limit in your account or with support.
  • Novita: limits use account tiers based on recent top-ups. Its public guide defines T1 through T5, but the current GLM-5.2 RPM/TPM values appear in the console rather than the public table. Higher limits require review and available capacity.
  • OpenRouter: paid accounts use high global limits plus upstream provider capacity. The /api/v1/key endpoint reports key limits, and provider routing can fall back when one route fails.

The calculator accepts peak concurrency because a low monthly bill can still create a sharp burst. Ten thousand requests spread across a month need little average RPM; ten requests launched at once can still hit a provider or token-per-minute limit.

Test at the same prompt size and concurrency as production. Measure 429 rate, 5xx rate, time to first token, tokens per second, full response latency and retry amplification. Keep failed attempts in the cost report.

Z.ai’s API Data Processing Addendum states that it does not store content supplied or generated through API Services and processes that content in real time. It can temporarily retain other customer data to provide the service or comply with law. The DPA also says customer data is generally processed in Singapore.

That language supports a strong default privacy case for business API traffic. It does not replace a signed agreement, a subprocessor review or your own application logs.

Novita’s Terms of Service state that it does not log, store or retain inputs, prompts, chat histories or outputs without prior written consent. Its console still provides operational metrics such as requests, non-5xx success rate and latency. Those metrics do not require storing prompt content.

Confirm whether any optional Logs feature changes content retention before enabling it. Keep trace IDs and metadata separate from confidential prompt bodies.

OpenRouter’s data collection guide says prompt and response content is not stored by default. It stores metadata such as tokens, latency and model. Optional private input/output logging stores content for at least three months and may keep it longer until deletion is requested. A separate opt-in exchanges content use for a 1% discount.

OpenRouter also supports per-request ZDR routing. ZDR filters endpoints; it does not make an unverified provider compliant with your industry rules. Review the selected endpoint policy and keep the setting under automated test.

Z.ai and Novita do not publish a current public GLM-5.2 serverless error-rate guarantee that we could verify. Novita exposes your own non-5xx success rate and latency in its metrics console. Its published 98% SLA covers standard dedicated endpoints, not the shared serverless model route, so we do not apply it here.

OpenRouter publishes rolling endpoint uptime in its public GLM-5.2 endpoints API. During our July 17 snapshot, active routes showed materially different one-day uptime. That observation supports provider pinning, fallback and monitoring; it does not predict next month’s uptime and is not a contractual SLA.

Error rate also depends on the definition. A 200 response with invalid JSON, an empty tool call or a wrong answer is an application failure even when the provider counts it as available. Track both transport success and task success.

Z.ai direct: best for first-party behavior

Section titled “Z.ai direct: best for first-party behavior”

Choose Z.ai when you want the publisher’s documented model limits, cache price and capability surface without a gateway selecting another host. The direct route removes one routing layer and has a clear API DPA. The tradeoff is less public model-specific availability and rate-limit data than a live gateway dashboard.

Read the official GLM-5.2 API guide.

Novita: best direct alternative with account metrics

Section titled “Novita: best direct alternative with account metrics”

Choose Novita when OpenAI compatibility, FP8 hosting, the full context/output contract and built-in account metrics fit your stack. The public list price matches Z.ai. Its rate limits depend on account tier, and the public docs do not state a shared-serverless processing region.

OpenRouter: best for routing and quick comparison

Section titled “OpenRouter: best for routing and quick comparison”

Choose OpenRouter when fallback, provider selection, policy filters, one billing layer and live endpoint metadata outweigh a fixed backend. Use order, allow_fallbacks, require_parameters, data_collection and zdr deliberately. Record the selected provider on every result.

Inspect the live GLM-5.2 route and provider table.

We performed a documentation and public-endpoint verification, not a paid model benchmark.

  • We opened the current Z.ai pricing, GLM-5.2 model, Coding Plan and DPA pages.
  • We checked Novita’s model page, terms, payment, rate-limit and metrics documentation.
  • We queried OpenRouter’s public model and endpoint APIs and reviewed its pricing, routing and privacy documentation.
  • We recalculated provider costs and the RunPod GPU floor used by the companion calculator.
  • We did not submit prompts, compare output quality, measure latency, create paid accounts or request enterprise contracts.

The absence of a paid test is a limit, not a hidden detail. Before production, replay a versioned dataset through the exact route, precision, parameters and tool schema you plan to buy.

GLM52.ai has affiliate relationships with Z.ai’s Coding Plan and Novita. We may receive compensation after a qualifying signup or purchase. Affiliate status did not change the published rates, missing-data labels or recommendations on this page. OpenRouter links are editorial and not affiliate links. Provider terms control all prices, discounts, credits and eligibility.

Primary sources checked on July 17, 2026, with Z.ai login, key-management and endpoint routes rechecked July 20: