GLM 5.4 rate limits and HTTP 429 Troubleshooting

Updated November 27, 2026

Z.ai Coding Plan and API error documentation · Claude API error reference

Check the Z.ai error code before retrying. Wait for the quota reset, lower concurrency, back off or correct the billing route according to the code.

Credit windows
Rolling 5 hours and weekly
Input / cached input / output
4.6 / 1.1 / 16
Off-peak credit rate
50% of standard

GLM 5.4 rate limits combine a rolling five-hour credit allowance with a weekly allowance. When Claude Code shows HTTP 429, read Z.ai’s error.code and error.message. Those fields tell you whether to wait for credits, reduce parallel requests, retry later or fix billing and routing.

Four troubleshooting cards for GLM 5.4 error codes 1308 and 1310, 1302, 1305 and 1113, with a separate note on HTTP 529 overload
Use the four-digit Z.ai code to pick a fix. HTTP 529 signals overload in Anthropic-style clients.

Five-hour and weekly Coding Plan quotas

Each personal Coding Plan tier enforces both limits. Five-hour credits refresh five hours after use, so a batch of requests can regain capacity in stages. The weekly balance resets every seven days from subscription activation. A job needs available credits in both windows. Check which window is exhausted before moving a build or review to another time. Team plan allowances follow separate rules. Z.ai’s Coding Plan credit rules.

Personal Coding Plan credits by tier
PlanRolling five hoursWeekly
Lite2,00010,000
Pro12,00060,000
Max28,000140,000

For GLM 5.4, multiply uncached input by 4.6, cached input by 1.1 and output by 16. Divide the sum by 10,000 to get the standard credit charge. Model calls consume half that amount outside Monday–Friday, 14:00–18:00 UTC+8. The off-peak rate changes the cost of each call within the same two allowances. For example, 10,000 uncached input tokens and 1,000 output tokens cost 6.2 credits at the standard rate and 3.1 off-peak. Add any separately billed Coding Plan MCP tool calls when budgeting a workflow that uses them. Use the GLM 5.4 token counter to estimate a busy block of work before choosing among GLM 5.4 Coding Plan tiers.

GLM 5.4 HTTP 429 and 529 troubleshooting table

Record the HTTP status, Z.ai code, reset time and response headers before retrying. The HTTP status describes the response at the protocol level. The body can narrow a 429 to several very different causes. For a 529 from an Anthropic-compatible gateway, use any upstream details supplied with the response. If a generic 429 has no Z.ai code, check the plan dashboard and the response headers first. Resume with a single request once you have confirmed credit headroom. Z.ai API error codes and Claude API error reference.

Choose the fix by status and error code
HTTPCodeMeaningWhat to do
4291308The usage window named in the response is exhausted. Check for the five-hour window on the Coding Plan.Queue work until the reset time in the message.
4291310Weekly or monthly usage exhausted. Personal Coding Plan credits use the weekly window.Wait for the returned reset time and verify the window in your plan dashboard.
4291302Request rate limit reached. Concurrent bursts can trigger it.Lower concurrency. Drain the queue gradually.
4291305Temporary service overload.Retry with bounded exponential backoff and jitter.
4291113Insufficient balance or no applicable resource package.If you intended to use plan credits, verify the Coding Plan endpoint, key and subscription. For metered usage, check the balance.
529Varies by gatewayTemporary overload on the Anthropic-compatible path.Honor Retry-After if present, then retry within a fixed time budget.

If 1113 appears after you subscribe, check where the client is sending the request. Claude Code uses https://api.z.ai/api/anthropic. Other clients can require another Coding Plan route. Correct the base URL and confirm the key before repeating the request. Z.ai’s Coding Plan billing FAQ. See GLM 5.4 Claude Code setup and the GLM 5.4 API endpoint guide for the matching configs.

Reduce 429s during long coding runs

  1. Cap parallel subagents. After a 1302, start with one active worker. Start the next when the first finishes and increase the cap only after the queue drains reliably. Let retries count against the same cap.
  2. Keep the prompt prefix stable. Put shared instructions, tool schemas and repository context first. Append the task and changing logs later. Warm turns reached 90–92% cache hits in AICodeKing’s tests. Measure yours across comparable turns. A cached token uses about one-quarter of the credits of an uncached token (4.6 ÷ 1.1 ≈ 4.18). At exactly 90% hits, 10,000 input tokens cost 1.45 standard credits instead of 4.6 when all 10,000 are uncached. Output charges are separate. See the GLM 5.4 benchmarks.
  3. Move heavy sweeps off-peak. Schedule repository-wide review and test batches outside the published peak window. Check the weekly balance before queuing a large run. Off-peak scheduling halves model credits per call.
  4. Bound retries. For 1305 or a transient 529, honor a valid Retry-After header. Otherwise, double the delay after each failed attempt up to a cap, and randomize each wait to spread retries across workers. Stop at a fixed deadline. If several workers are failing at once, hold the queue and resume with one worker to check whether the service has recovered. If a stream breaks after a file edit or tool action, check what finished before replaying any work.

Frequently asked questions

When do GLM 5.4 Coding Plan credits reset?

Five-hour credits refresh five hours after they are spent. Weekly credits reset every seven days from subscription activation.

Which GLM 5.4 error codes indicate exhausted quota?

1308 refers to the usage window named in the error. 1310 means the weekly or monthly allowance is exhausted. Use the reset time in the response.

What does Z.ai error 1113 mean?

Z.ai reports insufficient balance or no applicable resource package. For Claude Code on the Coding Plan, check the plan key and https://api.z.ai/api/anthropic base URL.

Should I retry HTTP 529 immediately?

Honor Retry-After when provided. Otherwise, use capped exponential backoff with jitter and a fixed retry deadline.