59API FAQ: API keys, model access, and Codex setup
Do I need one API key for every model?
The short answer is no. 59API is an independent third-party AI API relay, and the whole point is to keep access simple: one account, one API key, and one API host at https://api.59api.com. That same key is what you point at each model family, depending on which client you use and which protocol that client speaks. You are not juggling a separate account with every vendor.
Money works in a similarly predictable way. You top up a prepaid balance and 59API charges you per request based on real token usage. There is no monthly fee, and your balance never expires, so unused funds stay there until you spend them. Monthly and weekly cards are available if you prefer them, but they are optional rather than required.
Top-ups come in ¥10, ¥50, ¥100, ¥200, ¥500 and ¥1000, paid by WeChat Pay or bank card, and invoices are available. Billing is in CNY, with USD figures shown at ¥7.2 = $1. If you are wondering whether a single key is a good fit for a prototype or a production service, the answer depends on the client protocol rather than the number of models you want to try.
How do I set up Codex and OpenAI-compatible clients?
Codex, OpenAI SDKs, cURL and OpenAI-compatible clients such as Cursor, Cherry Studio, Cline and OpenCode all use the same OpenAI-style route on 59API. Set base_url to https://api.59api.com/v1 and point the chat endpoint at https://api.59api.com/v1/chat/completions, then send your 59API key as the bearer token.
One rule matters here: that route serves GPT, DeepSeek and other non-Claude, non-Gemini models only. If you are searching for a model id, use the exact id from the model list, for example gpt-6.1-sol, gpt-5.6-sol, deepseek-v4-pro, qwen3.8-max or glm-5.3.
Here is what a few of those models cost per 1 million tokens on 59API:
- GPT-6.1 Sol: input $0.1847 (¥1.33), output $0.9264 (¥6.67), cache read $0.0375 (¥0.27).
- GPT-5.6 Sol: input $0.3472 (¥2.5), output $1.94 (¥14), cache read $0.0278 (¥0.2).
- DeepSeek V4 Pro: input $1.25 (¥9), output $3.75 (¥27), cache read $0.0417 (¥0.3).
Because billing follows real token usage, a small test request costs a small amount, and you can watch usage grow as your prompts and completions get longer.
Which clients can reach Claude and Gemini models?
Neither of those two families is reachable from Codex, the OpenAI SDKs, cURL, or OpenAI-compatible clients such as Cursor, Cherry Studio, Cline and OpenCode. That is a protocol boundary, and it is worth stating plainly before you spend an afternoon debugging a request that was never going to work.
Claude models work only through the genuine Claude Code or Claude Desktop client, with Claude Code 2.1.285 or newer. For that client, set ANTHROPIC_BASE_URL=https://api.59api.com and ANTHROPIC_AUTH_TOKEN=YOUR_59API_KEY. Gemini models use Google's native protocol only, through Gemini CLI, with GOOGLE_GEMINI_BASE_URL=https://api.59api.com and GEMINI_API_KEY=YOUR_59API_KEY. They are not OpenAI-compatible and do not work on the /v1/chat/completions endpoint.
So the practical answer to a common question is: your single 59API key can serve every supported model, but each model family expects its own client and its own environment variables. If a request fails from a client that speaks the wrong protocol, moving to the matching client is the fix. Nothing else in your configuration changes between clients except the base URL, the endpoint style and the variable names.
How does 59API price requests?
Every rate on 59API is quoted per 1 million tokens, and you are charged on the tokens your request actually uses. There are three components to look at: input tokens, output tokens and cache reads. Input tokens are the material you send, output tokens are what the model writes back, and cache read covers a cached prompt being reused.
A few examples: MiniMax M3 is input $0.1389 (¥1), output $0.5556 (¥4), cache read $0.0278 (¥0.2) per 1 million tokens. Kimi K3 is input $1.11 (¥8), output $5.56 (¥40), cache read $0.1111 (¥0.8). Hunyuan 4 is input $0.3472 (¥2.5), output $1.11 (¥8), cache read $0.0167 (¥0.12).
Since the balance is prepaid and never expires, you can top up when it is convenient rather than racing a monthly deadline. There is no monthly fee to keep track of. For anyone who wants a predictable ceiling, cards add weekly caps on top of the balance, which is covered next.
One practical habit: check the input and output rates for your chosen model before you build a long-running loop, because output-heavy prompts cost more than input-heavy ones.
What does a real request cost?
Here are two worked examples using GPT models, with no cache involved. Take GPT-6.1 Sol at 5M input tokens plus 1M output tokens. On 59API that comes to $1.85 (¥13.32). The same usage at the official list price of $20 (about ¥144) puts 59API at about 9% of list price.
Now take GPT-5.6 Sol at 2M input tokens plus 0.5M output tokens. On 59API the cost is $1.67 (¥12). At the official list price of $18 (about ¥129.6), 59API is about 9% of list price. Official list price is only a reference figure, not a claim about any partnership or authorised channel.
These are straight arithmetic on the published per-million-token rates, which is exactly how your balance is charged: real token usage multiplied by the rate for the model you called. Billing is in CNY, with USD figures shown at ¥7.2 = $1, and there is no monthly fee layered on top of the token charge.
That predictability is what makes a relay like 59API pleasant to prototype with. You can estimate a month of usage from your token counts, top up with WeChat Pay or a bank card, and keep an eye on the balance without negotiating a contract.
Should I use a card or the prepaid balance?
Both are open to you, and the choice comes down to how you want spending to behave. A card has its own API key, can only call that family's models, and is paid only from the card. It never falls back to wallet balance, and a balance key never draws on a card. Unused quota does not roll over. Quota and caps are card metering units written in $, not official list-price dollars, so they should not be read as official prices.
Two examples: C-PRO Starter (Claude, 30 days) is $83.19 (¥599), with quota $610, weekly cap $230, and a reference value at official list prices of about $169.44 (¥1220). G-PRO Starter (GPT, 30 days) is also $83.19 (¥599), with quota $2300, weekly cap $880, and a reference value at official list prices of about $638.89 (¥4600). Both drain at the card's metering price × 2.4.
Cards also come in weekly form, such as the 7-day G-PRO $1100 card at $40.56 (¥292) with quota $1100 and weekly cap $1100.
For a first run, the prepaid balance is the simplest starting point: top up from ¥10, use one key, and see how your real token usage lands. If you later want a weekly ceiling or a dedicated key for one model family, add a card then.