Qwen 3.8 27B API, OpenAI-compatible
Alibaba’s Qwen 3.8 27B behind one OpenAI-compatible endpoint, served on Cloudflare Workers AI: a 262,144-token context window, tool calling verified by our contract tests, and image input we probed ourselves before switching it on. Prepaid USD credits, per-token billing you can audit, and 40% off the list price for the launch period.
What you get
- Context window
- 262,144 tokens (input + max_tokens)
- Image input
- Yes — verified on this model; send images as base64 data URIs
- Function calling
- Yes — calls tools with correct schemas in our contract tests
- Reasoning
- Yes — streamed as reasoning_content, billed once at the output rate
- Max output
- 4,096 tokens per request
- Upstream ID (public)
- @cf/qwen/qwen3.8-27b
- Privacy
- Runs on Cloudflare infrastructure; we log metadata only — never prompt or response content
Pricing (40% off list, applied automatically)
- Input
$0.45$0.27- Output
$3.20$1.92
@cf/qwen/qwen3.8-27b
Struck price = list. Live prices for all seven models are on the models page, synced from the billing database that rates your requests.
Measured, not quoted
Our own measurements, 2026-08-18. Live status and per-model numbers stay on the models page.
1.14 s
time to first token on a 2K-token prompt
165–195 ms / 1K tokens
prefill rate — slower than our DeepSeek Flash line
1.9 s
first byte on a 150K-token prompt (full answer starts later)
6 / 6
contract tests passed, including tool calls
Ship in two lines of config
If your code already talks to the OpenAI API, you change base_url and the key. Nothing else moves.
from openai import OpenAI
client = OpenAI(
base_url="https://api.clfaigateway.dev/v1",
api_key="sk-gw-...", # app.clfaigateway.dev
)
resp = client.chat.completions.create(
model="qwen3.8-27b",
messages=[{"role": "user", "content": "Explain this stack trace..."}],
stream=True,
)
for chunk in resp:
print(chunk.choices[0].delta.content or "", end="")Qwen 3.8 27B API — common questions
Yes, and we checked rather than trusting a spec sheet: we sent it images and confirmed it answered from what was in them. Send images inline as base64 data URIs; remote http(s) links are not fetched. We have verified plain images — we have not measured small print, scanned documents or dense charts, so we do not promise OCR.
How to send images →About 1.1 s to first token on a short prompt. Prefill is the slower part — roughly 165–195 ms per 1,000 input tokens, several times slower than our DeepSeek Flash line — so a very large prompt takes real time before the answer starts. First byte still arrives in about 1.9 s even at 150K tokens, so stream and your users see progress immediately.
Compare models →Not on this model today. Prefix caching is not active for it in our measurements, so we price cached input the same as regular input rather than advertising a saving you would not get. If that changes we will reprice it, and the models page always shows the live rate.
Context & caching docs →Prepaid credits, per real token, at the current per-model price — 40% off list during the launch period, applied automatically. Every request returns its exact cost, and a failed request that produced nothing costs $0.
Billing docs →