---
title: "Create Turn"
method: POST
path: "/api/sessions/{session_id}/turns"
tags: ["turns"]
---

# Create Turn

`POST /api/sessions/{session_id}/turns`

Stream one Turn, opening claim and preparation inside the SSE generator.

## Path parameters

- `session_id` string, uuid, required

## Headers

- `Idempotency-Key` string, required

## Request body

- CreateTurnRequest — Canonical body for POST /api/sessions/{session_id}/turns.
  - `text` string, required
  - `attachment_ids` string[]
  - `skill_selections` SkillSelectionRequest[]
    - `id` string, uuid, required
    - `expected_version` string, required

## Response `200`

AI SDK UI v1 UIMessage SSE stream. It opens immediately with a transient data-status prelude (phase=preparation) that repeats every runtime heartbeat until the Turn is claimed and prepared. Claim or preparation failures no longer change the HTTP status: they project closed error + finish chunks inside the stream, and cancellation projects one abort chunk.

## Other responses

- `422` — Invalid request
- `503` — Turn unavailable while composition installs dependencies

## Changes

- **2026-08-08** `a60cd3a6119c` — 1 warning, 3 info
  - the optional response header `X-Fleet-Run-ID` removed for the status `200`
  - removed the non-success response with the status `404`
  - removed the non-success response with the status `409`
  - removed the non-success response with the status `504`
- **2026-07-17** `655778279cb1` — 1 info
  - endpoint added
- **2026-07-17** `62e8c152aa18` — 1 breaking
  - api path removed without deprecation
- **2026-07-16** `a0bc9eaf12e0` — 1 breaking
  - removed the media type `application/json` for the response with the status `200`
- **2026-07-15** `216311cd30ec` — 3 warning
  - deleted the `header` request parameter `Authorization`
  - deleted the `header` request parameter `X-Fleet-User-Id`
  - deleted the `header` request parameter `X-Fleet-Workspace-Id`

[Full history](https://skmtc.dev/qredence/apis/fleet-rlm/changes/api/sessions/:session_id/turns/post.md)

---

[API](https://skmtc.dev/qredence/apis/fleet-rlm.md) · [All operations](https://skmtc.dev/qredence/apis/fleet-rlm/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/qredence/fleet-rlm/revisions/3e0490b230d7/schema)
