You create a Qwen API key in Alibaba Cloud Model Studio: open an Alibaba Cloud account, pick a region in the console and click Create API Key. The vendor expects payment by bank card or a wallet such as PayPal, and its documentation is silent about Russia: we found no list of banned countries and no word about Russian cards. If sign-up or payment does not work, a gateway is left: Qwen models on a Claudexia key, topped up from $1 with rubles or crypto.
How to get a Qwen API key
Alibaba serves Qwen through two consoles: Alibaba Cloud Model Studio (documented on alibabacloud.com) and QwenCloud (qwencloud.com). Prices matched on both in the rows we compared, and the free-quota rules are close, but the start of the term and the path to the switch are described differently (below). QwenCloud admits only main Alibaba Cloud International accounts, with sign-in by email or GitHub, and RAM users are not supported. How Alibaba itself describes the difference between the two consoles, we did not find.
The steps below follow the Model Studio documentation and the Alibaba Cloud sign-up page:
- Register an account on the Alibaba Cloud international site: email, password, account type (Individual or Enterprise), country and a verification code. The country sets your billing currency and taxes and cannot be changed after registration. The phone number must belong to the country you chose, or the code will not arrive.
- Finish the registration: mobile number, payment method, billing address. Without this the system blocks an order for a paid product outside the Chinese mainland and says the account information is incomplete.
- In the Model Studio console open the API Key page, pick a region in the upper-right corner and click Create API Key. The documentation recommends leaving the workspace at its default; the description is optional, and permissions are All or Custom.
- Save the key at once. After you close the dialog the full key is not shown again: a lost key is reset or replaced with a new one. Keys of the new format start with
sk-ws. - Put the address and the key into your client. The console shows the address in the same dialog.
Keys are tied to a region, and every region has its own address and its own model list. There are six regions: Singapore, Beijing, Frankfurt, Hong Kong, Tokyo and Virginia (US). QwenCloud opens its console in Singapore by default, and Alibaba's examples use Singapore too.
import os
from openai import OpenAI
client = OpenAI(
api_key=os.environ["DASHSCOPE_API_KEY"],
base_url="https://ap-southeast-1.maas.qwencloudapi.com/compatible-mode/v1",
)
reply = client.chat.completions.create(
model="qwen3.8-flash",
messages=[{"role": "user", "content": "Reply with one word: ok"}],
)
print(reply.choices[0].message.content)
The variable name and the shape of the address come from the QwenCloud documentation, and we did not send this request. The Model Studio console uses a different address that carries a workspace ID: https://{WorkspaceId}.ap-southeast-1.maas.aliyuncs.com/compatible-mode/v1. Take the key and the address from the same console and the same region; we did not try mixing consoles. Besides the OpenAI format, Alibaba also offers an Anthropic-compatible one.
What "Qwen API for free" means
The documentation shows no permanent free tier, only a quota for new accounts. According to the Model Studio page and the QwenCloud page, the terms are:
| Term | What the page says |
|---|---|
| Size | usually 1,000,000 tokens per model, input and output counted together, and the quota does not move between models |
| Duration | 90 days. In Model Studio the count runs from the latest of three dates: Model Studio activation, the model's release, approval of your request for the model (registering an Alibaba Cloud account does not start it). In QwenCloud it runs from account activation, and for models released later from the model's release date. An unused remainder expires |
| Where | Singapore only: real-time calls made with a key created in Singapore |
| Not covered | batch calls, built-in tools such as web search, fine-tuning, deployment |
| What you need | add payment details, otherwise the quota is not granted; if the account was opened before payment was verified, calls are blocked after the quota runs out (error AllocationQuota.FreeTierOnly) |
| After the quota runs out | with verified payment, calls switch to pay-as-you-go billing by themselves. To make them stop, turn on Free quota only beforehand (it is off by default). In QwenCloud: the Free Tier page, the switch for the model you need. In Model Studio: Model usage, the Free Quota tab, the Free Quota Only switch for the model you need. It cannot be turned on for a model with no quota or an exhausted one, and in Model Studio a switched-on setting takes effect with a delay |
| Registering again | grants no extra quota |
For some models the quota was withdrawn. The list of withdrawals dated 15 November 2026 includes qwen3.8-max-0902: new users do not receive it, and quota already issued stays valid until it expires. Meanwhile the QwenCloud price table for Singapore shows "1 million Tokens" in the quota column for qwen3.8-max and qwen3.8-flash, while a line above the Flash table says the models listed there have no free quota in any region. The pages contradict each other. The Free Tier page in QwenCloud or the Free Quota tab in Model Studio shows what your account actually gets.
The QwenCloud billing page allows skipping the payment details if you only want the quota, but warns that some features will be restricted. The quota page requires the details for activation. Go by the stricter version.
Vendor prices for Qwen 3.8
Prices per 1M tokens, standard, with no promotions and no cache. Sources: the Model Studio pages for qwen3.8-max and qwen3.8-flash and the QwenCloud price table, compared on 19 November 2026.
| Model | Singapore, input / output | Beijing and scope Global, input / output |
|---|---|---|
| qwen3.8-max | $2 / $6 | $1.65 / $4.951 |
| qwen3.8-flash | $0.15 / $0.47 | $0.113 / $0.382 |
| qwen3.8-omni-flash | $0.15 / $0.47 | $0.113 / $0.382 |
For qwen3.8-max, Beijing and scope Global (Frankfurt, Tokyo, Hong Kong, Virginia) cost the same. The quota works only in Singapore, and in other regions billing starts with the first token. The context window of qwen3.8-max and qwen3.8-flash is 1,000,000 tokens, and the maximum output is 131,072. For qwen3.8-omni-flash we did not compare the limits.
Next to the 3.8 line the same pages list qwen4-max: Model Studio marks it as the Latest Model, and the QwenCloud table prices it at $1.5 / $4.5 for Singapore. The Claudexia catalog did not have it on 19 November 2026. We did not check its release date. What the 3.8 models are and how they differ is covered in our Qwen 3.8 overview, so we do not repeat it here.
How to pay for Qwen API at the vendor
QwenCloud's billing description is postpaid, not prepaid like OpenAI. According to the QwenCloud billing page, the system by default charges your card when accrued usage reaches $1,000, and takes the rest of the month in a single payment at month end.
To spend beyond the quota you add a payment method. QwenCloud lists Visa, Mastercard, JCB, American Express, UnionPay, Diners Club and Discover cards, PayPal, Google Pay and Apple Pay. The set depends on the country and currency of the account. A card needs a name, an address, a postal code, a phone number confirmed by a code, and three conditions: online payments and international transactions enabled, 3-D Secure enabled, and enough balance for a $1 pre-authorization. That $1 shows on the bank statement as ALIBABACLOUD.COM, and the bank usually cancels it within 1-5 business days. Alibaba charges no fee for card payments, though your bank may charge for currency conversion. One card or one PayPal account can be linked to only one Alibaba account.
Which methods you see depends on the Alibaba contracting entity. According to the payment methods page, your place of residence or the billing address from registration decides it, and the entity is named in the agreement you accept at sign-up. Russia is not named in the list, and the page does not say which row Russia falls under ("other European jurisdictions outside the EEA" or "other jurisdictions"). Visa and Mastercard are marked for all five entities in the methods table, while JCB and the Cryptocurrency (stablecoin) row via TripleA appear only for the Singapore entity. Whether that row works for Model Studio, and whether you can pay with it from Russia, we did not check.
Why payment from Russia may fail
The word "Russia" appears on none of the pages we opened: not in country lists, not in the agreement texts, not in the payment methods. So we can confirm neither "Alibaba does not accept Russian cards" nor "it does". The causes of declined payments that the documentation does name:
| Cause | What the documentation says | What to check |
|---|---|---|
| Card type | prepaid, virtual and gift cards are not accepted because they fail pre-authorization; credit cards issued in the Chinese mainland are not accepted either | that the card is an ordinary credit or debit card |
| Bank settings | online payments, international transactions, 3-D Secure and $1 of free funds are required | the bank app, limits on foreign payments |
| Country and phone | the country cannot be changed after registration, the phone must belong to that country, and the country decides the entity and the payment methods | the registration form, the Country/Region field |
| Risk control | for an account under restrictions you cannot buy, top up or activate a postpaid product; identity verification takes a passport or a driver's license and about three business days | the email from Alibaba and the identity verification section |
| Terms | Product Terms section 3.6 makes compliance with export control and "international or country-specific sanctions programs" a condition of use | the terms themselves |
In the Model Studio part of the same terms (section 4.48) Alibaba reserves the right to suspend or end access if the law requires it or if it sees an elevated risk of non-compliance with legal requirements. Whether these clauses apply to you, we do not assess. We give no legal opinions and do not promise that any method is lawful or safe for your account. You read and accept the vendor's terms.
We did not check the sign-up itself with a Russian phone number, the country list in its form, or a pre-authorization with a card from a Russian bank. We do not describe schemes with another country in the form, virtual cards or a spoofed address: the country is not changed after registration, and the documentation rules virtual cards out explicitly. For access to the Qwen Studio chat from Russia we have a separate article, which is available in Russian only.
Qwen through Claudexia: the sk_cdx_ key and prices
Claudexia gives you the Qwen 3.8 models over an API, without an Alibaba account. The balance is separate: sign up with a login and password or through Google, GitHub or Telegram, top up from $1 with a Russian card, through SBP (Russia's Faster Payments System) or with crypto, and get a key like sk_cdx_.... The address for OpenAI-compatible clients is https://api.claudexia.tech/v1. Qwen is in the Premium channel only; on 19 November 2026 the Cheap channel has none.
Claudexia prices from the public price list on 19 November 2026, next to the vendor's Singapore prices from the table above, per 1M tokens:
| Model | Claudexia, input / output | Vendor, Singapore | Context | Max output in the catalog |
|---|---|---|---|---|
| qwen3.8-max | $1.86 / $5.54 | $2 / $6 | 1,000,000 | 32,000 |
| qwen3.8-flash | $0.28 / $0.74 | $0.15 / $0.47 | 1,000,000 | 32,000 |
| qwen3.8-omni-flash | $0.28 / $0.90 | $0.15 / $0.47 | 1,000,000 | 65,536 |
For qwen3.8-max the Claudexia numbers are below the vendor's Singapore list ($1.86 against $2 and $5.54 against $6) and above the Beijing and scope Global prices ($1.65 and $4.951). For qwen3.8-flash and qwen3.8-omni-flash the vendor is cheaper: input $0.15 against $0.28, output $0.47 against $0.74 and $0.90. If payment to Alibaba works for you and you need only these two models, paying the vendor directly is cheaper by the price lists. There is one more difference: the catalog caps output at 32,000 tokens for qwen3.8-max and qwen3.8-flash, while Alibaba's documentation gives 131,072.
import os
from openai import OpenAI
client = OpenAI(
base_url="https://api.claudexia.tech/v1",
api_key=os.environ["CLAUDEXIA_API_KEY"],
)
reply = client.chat.completions.create(
model="qwen3.8-flash",
messages=[{"role": "user", "content": "Reply with one word: ok"}],
)
print(reply.choices[0].message.content)
The model IDs are in the response of GET https://api.claudexia.tech/v1/models (on 19 November 2026 it lists 64 models, and all three Qwen models are among them). We did not send the request above for this article. We did not test the Anthropic Messages format with models outside the Claude family, so for Qwen use the address with /v1. Current prices are on the models page, and the quickstart is in the documentation. The same "key, prices, payment" walk-through for another vendor is in How to top up the DeepSeek API, and a comparison of Qwen with Claude by task is in Claude vs Qwen in 2026. If you also weigh OpenRouter as a way to pay, see OpenRouter payment blocked.
FAQ
Where do I get a Qwen API key?
In the Alibaba Cloud Model Studio console on the API Key page, or in QwenCloud. You need an Alibaba Cloud account, you pick the region in the upper-right corner, and you create the key with the Create API Key button, which shows it once. The key works only with the address of the region where it was created.
Is there a free Qwen API?
There is no permanent free tier. New accounts usually get 1,000,000 tokens per model for 90 days, in Singapore only and after payment details are entered. As of 19 November 2026 the quota for qwen3.8-max-0902 was withdrawn, and the vendor's pages disagree about the quota for qwen3.8-flash. Check the Free Tier page in QwenCloud or the Free Quota tab in Model Studio. The Claudexia catalog does have a free model, but it is not Qwen.
How much does the Qwen API cost?
At the vendor in Singapore, qwen3.8-max costs $2 per 1M input tokens and $6 per 1M output tokens, and qwen3.8-flash and qwen3.8-omni-flash cost $0.15 and $0.47. In the Claudexia catalog on 19 November 2026 these are $1.86 / $5.54, $0.28 / $0.74 and $0.28 / $0.90.
Does paying for the Qwen API work from Russia?
Alibaba's documentation names Russia neither among supported nor among banned countries, and we did not test payment with a card from a Russian bank. It does set general requirements: an ordinary card with international payments and 3-D Secure, a $1 pre-authorization, a ban on prepaid and virtual cards, and clauses on sanctions and export control in the agreement.
How do I buy Qwen API if payment to Alibaba fails?
Use a gateway. Claudexia issues an sk_cdx_... key after sign-up and a top-up from $1 with a Russian card, through SBP or with crypto, and no Alibaba account is needed. The vendor's terms and the gateway's rules stay with you: we give no legal opinions.