---
title: "Chat Completions"
method: POST
path: "/v1/chat/completions"
---

# Chat Completions

`POST /v1/chat/completions`

## Request

- Base URL: `https://api.stremai.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.stremai.com/v1/chat/completions`
- Auth: none declared

OpenAI-compatible chat completions endpoint.

Drop-in replacement — change your base_url and API key, everything else works.

## Request body

- ChatCompletionRequest
  - `model` string, required
  - `messages` ChatMessage[], required
    - `role` string, required
    - `content` union
      - string
      - unknown[]
        - unknown
    - `name` string, nullable
    - `tool_calls` unknown[], nullable
      - unknown
    - `tool_call_id` string, nullable
  - `temperature` number, nullable
  - `top_p` number, nullable
  - `n` integer, nullable
  - `stream` boolean, nullable
  - `stop` union
    - string
    - string[]
  - `max_tokens` integer, nullable
  - `presence_penalty` number, nullable
  - `frequency_penalty` number, nullable
  - `logit_bias` object, nullable
  - `user` string, nullable
  - `tools` ToolDef[], nullable
    - `type` string
    - `function` FunctionDef, required
      - `name` string, required
      - `description` string, nullable
      - `parameters` object, nullable
  - `tool_choice` union
    - string
    - object
  - `response_format` ResponseFormat
    - `type` string
  - `seed` integer, nullable

## Response `200`

Successful Response

- unknown

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/stremai/apis/strem-ai.md) · [All operations](https://skmtc.dev/stremai/apis/strem-ai/llms.txt) · [OpenAPI document](https://skmtc.dev/stremai/apis/strem-ai/revisions/160e5f136d48?raw)
