General FAQ
Answers to the most common questions about RKAPI domains, error codes, billing, model groups, streaming, and support diagnostics.
Why am I getting HTTP 403 with api_domain_required?
You are sending model API requests to the web console domain (https://s2pbxm0xv5y.adtyai-fz.top) instead of the dedicated API gateway domain (https://api.zwwbai.com).
How to fix it:
- Replace
https://s2pbxm0xv5y.adtyai-fz.topwithhttps://api.zwwbai.comin your client config or environment variables. - Check whether your client expects
/v1at the end:- OpenAI SDKs, Codex CLI, OpenCode:
https://api.zwwbai.com/v1 - Claude Code, Anthropic SDKs, Gemini
google-genaiSDK:https://api.zwwbai.com
- OpenAI SDKs, Codex CLI, OpenCode:
- Restart your terminal or client so updated environment variables take effect.
See Quick Start & Dual Domains for details.
What do 401, 403, 429, and 5xx errors mean?
401 Unauthorized: Your API key is missing, mistyped, expired, disabled, or revoked (including if a team employee was disabled or removed from a team). Verify the exactsk-...key in API Keys and check that you are sending the right header (Authorization: Bearervsx-api-keyvsx-goog-api-key).403 Forbidden(insufficient_user_quota/ Insufficient Quota): RKAPI returns HTTP403(error codeinsufficient_user_quota) when your wallet balance (or shared team wallet balance) is too low to cover the request, or when the specific API key reaches its configured USD quota limit. Top up in Wallet or raise the key's quota cap. (Other403responses includeapi_domain_requiredor model/IP allowlist denials. If HTTP402appears, it can only come from an upstream provider passthrough rather than RKAPI's balance check.)429 Too Many Requests: Request-per-minute (RPM), token-per-minute (TPM), or concurrent-request capacity was temporarily exceeded. Slow down parallel bursts and retry using exponential backoff.500/502/503/504: A transient upstream provider error or timeout occurred. Retry after a short delay, and inspect Channel Availability to check whether the upstream route is experiencing an incident.
How do USD billing, quotas, and token counting work?
- USD accounting: Your wallet balance and every charge in Usage Logs are denominated in USD.
- Token-based calculation: Each model has published base rates for input tokens, output tokens, and (where applicable) prompt cache reads/writes or image generation units. Your actual cost equals the measured usage multiplied by the pricing multiplier of the concrete model group assigned to your API key.
- Reasoning & cached tokens: Reasoning models count internal reasoning tokens as part of output billing per upstream specification. Prompt cache hits significantly reduce input token cost on supported models—see Claude Code Cache Fix if you use Claude Code heavily.
- No hidden overhead: Every completed call shows its exact token counts and USD cost inside Usage Logs.
How should I choose a model group when creating an API key?
Every API key must be assigned to a concrete model group listed on the console's Pricing page. To pick the right group:
- Open Pricing in the console at https://s2pbxm0xv5y.adtyai-fz.top and inspect which concrete groups include the models you need and at what pricing multiplier.
- Open https://s2pbxm0xv5y.adtyai-fz.top/model-status (Channel Availability) and compare 24-hour heartbeat stability, latency, and success rate across those groups.
- Select your preferred concrete group when creating the API key.
If you need different routing tiers for different tools—such as one group for interactive coding in Claude Code and another for batch jobs—create separate API keys bound to each concrete group.
Why do long streaming requests time out or disconnect mid-response?
Mid-stream disconnects are usually caused by one of four factors:
- Aggressive client timeout: Many HTTP clients default to a 30-second or 60-second read timeout. Reasoning models or complex coding tool calls may pause silently before streaming tokens. Raise your client's read/stream timeout to at least
180s–300s. - Local proxy or VPN buffering: Some corporate proxies or VPN clients buffer Server-Sent Events (SSE) or close idle TLS sockets early. Test with direct connectivity or a stable proxy configuration.
- Oversized prompt context: Very large conversation histories increase time-to-first-token (TTFT). Compact long threads periodically.
- Upstream provider instability: Verify the model's live 24-hour heartbeat on Channel Availability.
How do I find a Request ID for a support ticket?
When opening a ticket in the Support Center about a failed or unexpectedly billed call:
- Sign in to https://s2pbxm0xv5y.adtyai-fz.top and open Usage Logs.
- Filter by time range, API key, or model name to locate the relevant entry.
- Click or expand the row to copy the Request ID (also returned in response headers on API calls when available).
- Paste the Request ID, timestamp, model name, and error message into your support ticket so staff can trace the exact gateway log immediately.