Back to Models

Qwen Long

qwenqwen/qwen-long

How TheRouter serves this differently from the vendor

As the vendor operates it

Alibaba Bailian documents qwen-long as a CN-hosted long-context model with 10M-token context, 8,192-token output, text-in/text-out, direct HTTP guidance of 1M tokens, and file submission recommended above that length.

On TheRouter

TheRouter exposes qwen/qwen-long on the OpenAI-compatible chat path with a catalog context length of 10,485,760 tokens and CN-region Bailian serving. The page therefore treats 10M as the vendor contract and 10,485,760 as TheRouter's operational catalog value, and warns that direct long prompts need validation.

API guide

Long-document chat

Use the OpenAI-compatible chat endpoint for long text prompts. Keep direct HTTP requests under the upstream 1M-token guidance unless your integration has an approved file-submission path.

cURL
curl https://api.therouter.ai/v1/chat/completions \
  -H "Authorization: Bearer $THEROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"qwen/qwen-long","messages":[{"role":"user","content":"Summarize the attached long document text: ..."}],"max_tokens":1200}'

Extraction with JSON-shaped instructions

Alibaba marks structured output as unsupported upstream, so treat JSON formatting as best-effort prompting rather than a guaranteed constrained decoder.

cURL
curl https://api.therouter.ai/v1/chat/completions \
  -H "Authorization: Bearer $THEROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"qwen/qwen-long","messages":[{"role":"system","content":"Return compact JSON only."},{"role":"user","content":"Extract parties, dates, and obligations from this contract: ..."}],"max_tokens":1000}'
Fact ledger β€” every claim on this page traces here
sourceURLretrieved
Context lengthhelp.aliyun.com β†—2026-08-01verified
Direct HTTP input limithelp.aliyun.com β†—2026-08-01verified
Maximum outputhelp.aliyun.com β†—2026-08-01verified
Modalitieshelp.aliyun.com β†—2026-08-01verified
Unsupported upstream featureshelp.aliyun.com β†—2026-08-01verified
Published mainland China quotahelp.aliyun.com β†—2026-08-01verified
Public long-context benchmark suitehelp.aliyun.com β†—2026-08-01unknown
Document QA benchmarkhelp.aliyun.com β†—2026-08-01unknown
Latency / throughput benchmarkhelp.aliyun.com β†—2026-08-01unknown
Alibaba lists qwen-long snapshot and qwen-long-latest alongside the base routehelp.aliyun.com β†—2026-08-01verified
Is qwen/qwen-long really a 10M-token model?help.aliyun.com β†—2026-08-01to verify
Does qwen-long support function calling or structured output?help.aliyun.com β†—2026-08-01to verify
When should I choose qwen-long instead of qwen-plus?help.aliyun.com β†—2026-08-01to verify
Help & contact