---
title: "Create a new chat conversation"
method: POST
path: "/{version}/{account_id}/{project_id}/chat/create"
---

# Create a new chat conversation

`POST /{version}/{account_id}/{project_id}/chat/create`

Creates a new chat conversation and returns the conversation ID along with the agent's initial response.

## Path parameters

- `version` string, required
- `account_id` string, required
- `project_id` string, required

## Headers

- `X-API-KEY` string, required
- `X-TOKEN` string, required

## Request body

- CreateChatRequest
  - `integration_attributes` object — Custom metadata passed from external integrations. Accessible in functions via conv.integration_attributes.
  - `variant_id` string — Specify which variant to use for this conversation. Useful for multi-site deployments.
  - `channel` 'webchat' | 'whatsapp' | 'sms' | 'api' — Channel identifier for the conversation.
  - `asr_lang_code` string — Language code for speech recognition (ISO 639-1 with region).
  - `tts_lang_code` string — Language code for text-to-speech (ISO 639-1 with region).

## Response `200`

OK

- CreateChatResponse
  - `conversation_id` string, required — Unique ID for the created conversation
  - `response` string, required — Initial response message from the agent

## Other responses

- `400` — Validation error.
- `401` — Missing or invalid API key.
- `403` — Missing or invalid API key.
- `404` — Resource not found.
- `500` — Internal Server Error.

---

[API](https://skmtc.net/poly/apis/polyai-agents-api.md) · [All operations](https://skmtc.net/poly/apis/polyai-agents-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/poly/polyai-agents-api/versions/76f3c606e395/schema)
