1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
const axios = require('axios');
const api_key = "YOUR API-KEY";
const url = "https://api.segmind.com/v1/qwen3-coder-plus";
const data = {
"messages": [
{
"role": "user",
"content" : "tell me a joke on cats"
},
{
"role": "assistant",
"content" : "here is a joke about cats..."
},
{
"role": "user",
"content" : "now a joke on dogs"
},
]
};
(async function() {
try {
const response = await axios.post(url, data, { headers: { 'x-api-key': api_key } });
console.log(response.data);
} catch (error) {
console.error('Error:', error.response.data);
}
})();An array of objects containing the role and content
Could be "user", "assistant" or "system".
A string containing the user's query or the assistant's response.
To keep track of your credit usage, you can inspect the response headers of each API call. The x-remaining-credits property will indicate the number of remaining credits in your account. Ensure you monitor this value to avoid any disruptions in your API usage.
Qwen 3 Coder Plus is Alibaba Cloud's premium code generation model, purpose-built for software engineering at scale. It is the proprietary, production-optimized API version of the Qwen3-Coder-480B-A35B architecture — a 480-billion-parameter Mixture-of-Experts model with 35 billion active parameters per inference call.
What sets Qwen 3 Coder Plus apart is its 1,000,000-token context window, enabling it to process entire codebases, large pull requests, multi-file projects, and long conversation histories without losing context. It is trained on 7.5 trillion tokens with a 70% code ratio, making it one of the most heavily code-trained models available via API.
Performance benchmarks position it as state-of-the-art among open models on Agentic Coding, Agentic Browser-Use, and Agentic Tool-Use — comparable to Claude Sonnet 4, with a 70.6% score on SWE-Bench Verified.
Qwen 3 Coder Plus excels wherever code quality and context depth matter:
For code generation, specify the language, framework, target environment, and expected input/output behavior. Including example data or failing test cases dramatically improves output accuracy. When working on agentic tasks, provide a clear objective, the available tools, and any relevant context from your codebase.
Qwen 3 Coder Plus supports function calling natively — define your tools in OpenAI format and the model will invoke them correctly. For long-context tasks (full repos, large PRs), the model handles up to 1M tokens but responses may take longer — set generous timeout and max-token limits.
How does Qwen 3 Coder Plus compare to GPT-4o for coding? On agentic coding benchmarks like SWE-Bench Verified (70.6%), it is competitive with or exceeds leading proprietary models including Claude Sonnet 4.
What languages does it support? All major programming languages including Python, JavaScript, TypeScript, Java, Go, Rust, C/C++, SQL, and dozens more.
Can it handle full repository context? Yes — the 1M token context window supports ingesting entire codebases in a single API call.
Does it support function calling and tool use? Yes. Qwen 3 Coder Plus natively supports OpenAI-format function calling for agentic workflows.
What is the maximum output length? Up to 65,536 tokens per response — sufficient for generating large files, complete modules, or detailed documentation.
Is this model open source? The base Qwen3-Coder-480B-A35B weights are open on Hugging Face under a permissive license. Qwen 3 Coder Plus is the production-optimized API version hosted by Alibaba Cloud via Segmind.