---
title: "Chat with a capsule"
method: POST
path: "/chat/completions"
tags: ["Chat"]
---

# Chat with a capsule

`POST /chat/completions`

## Request body

- ChatCompletionRequest
  - `messages` object[] — Array of messages in the conversation
    - `role` string — Role of the message sender (e.g., 'user' or 'assistant')
    - `content` string — Content of the message

## Response `200`

Successful response

## Other responses

- `400` — Bad request
- `500` — Internal server error

---

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