---
title: "Create a conversation."
method: POST
path: "/api/v1/projects/{projectId}/conversations"
tags: ["Conversations"]
---

# Create a conversation.

`POST /api/v1/projects/{projectId}/conversations`

## Request

- Base URL: `https://app.customgpt.ai`
- URL: `https://app.customgpt.ai/api/v1/projects/{projectId}/conversations`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/poll-the-people/apis/customgpt-ai/docs/api/v1/projects/:projectId/conversations/post.ts> (a function with typed inputs; its response is checked against the schema)

Creates a new conversation session for an agent. Returns a session ID that you'll use to send messages. You can optionally provide a name to help identify the conversation later.

Notes: You can also create conversations implicitly by sending a message with a new session ID.

## Path parameters

- `projectId` integer, required

## Request body

- object
  - `name` string: Conversation name

## Response `201`

Create a new conversation

- object
  - `status` 'error' | 'success': The status of the response
  - `data` Conversation
    - `created_at` string, date-time: When was this conversation created?
    - `updated_at` string, date-time: When was this conversation updated?
    - `deleted_at` string, date-time: When was this conversation deleted?
    - `id` integer: Conversation ID
    - `name` string: Conversation name
    - `project_id` string: Agent ID for this conversation
    - `created_by` string: User ID for the user who created this conversation
    - `session_id` string, uuid: Session ID for this conversation

## Other responses

- `400`: Bad Argument
- `401`: API Token is either missing or invalid
- `404`: Agent not found
- `429`: Too many requests. You have exceeded your API rate limit.
- `500`: Internal Server Error

## Changes

- **2026-11-03** `77aab4354382`: 4 warning, 1 info
  - added the new `422.00` enum value to the `data/code` response property for the response status `400`
  - added the new `422.00` enum value to the `data/code` response property for the response status `401`
  - added the new `422.00` enum value to the `data/code` response property for the response status `404`
  - added the new `422.00` enum value to the `data/code` response property for the response status `500`
  - …1 more
- **2026-07-17** `b80e6dfcf78d`: 2 warning, 2 info
  - added the new `Agent id is required` enum value to the `data/message` response property for the response status `404`
  - added the new `Agent with id {projectId} not found` enum value to the `data/message` response property for the response status `404`
  - removed the `Project id is required` enum value from the `data/message` response property for the response status `404`
  - removed the `Project with id {projectId} not found` enum value from the `data/message` response property for the response status `404`
- **2023-07-27** `2cd2d58839d0`: 1 info
  - added the non-success response with the status `400`
- …earlier changes not shown

[Operation history](https://skmtc.dev/poll-the-people/apis/customgpt-ai/changes/api/v1/projects/:projectId/conversations/post.md)

---

[API](https://skmtc.dev/poll-the-people/apis/customgpt-ai.md) - [All operations](https://skmtc.dev/poll-the-people/apis/customgpt-ai/llms.txt) - [OpenAPI document](https://skmtc.dev/poll-the-people/apis/customgpt-ai/revisions/77aab4354382?raw)
