---
title: "Create chat completion with Qwen 32B"
method: POST
path: "/chat/completions"
tags: ["Chat Completion"]
---

# Create chat completion with Qwen 32B

`POST /chat/completions`

Create a chat completion for given messages with streaming support

## Request body

- object
  - `messages` object[], required — Array of messages in the conversation
    - `role` 'system' | 'user' | 'assistant', required — The role of the message sender
    - `content` string, required — The content of the message
  - `model` 'RedHatAI/QwQ-32B-FP8-dynamic', required — Model identifier
  - `stream` boolean — Whether to stream the response
  - `temperature` number — Sampling temperature
  - `max_tokens` integer — Maximum number of tokens to generate
  - `top_p` number — Nucleus sampling parameter
  - `stop` string[], nullable — Sequences where the API will stop generating

## Response `200`

Successful chat completion

- object
  - `id` string — Unique identifier for the completion
  - `choices` object[]
    - `delta` object
      - `content` string — Generated text content
    - `index` integer — Index of the choice
    - `finish_reason` 'stop' | 'length' | 'content_filter' — Reason for finishing the generation

## Other responses

- `400` — Invalid request parameters
- `401` — Unauthorized - Invalid token
- `500` — Internal server error

---

[API](https://skmtc.dev/simplismart/apis/flux-dev-api.md) · [All operations](https://skmtc.dev/simplismart/apis/flux-dev-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/simplismart/flux-dev-api/revisions/3c868a866748/schema)
