---
title: "Create a sandbox chat"
method: POST
path: "/api/v1/chats"
tags: ["chats"]
---

# Create a sandbox chat

`POST /api/v1/chats`

## Request

- Base URL: `https://api.izap.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.izap.ai/api/v1/chats`
- Auth: HTTP bearer

Creates a trainer sandbox conversation for the business named in the `business-id` header. Sandbox chats exercise an assistant without messaging a real customer, and a business with no connected WhatsApp number may keep only a limited number of them.

## Headers

- `business-id` string, uuid, required

## Request body

- CreateChatIn
  - `session_id` string, uuid, nullable
  - `instructions` unknown[], nullable
    - unknown
  - `chatbot_id` string, uuid, nullable

## Response `200`

Successful Response

- ChatOut
  - `id` string, uuid, required
  - `conversation_id` string, uuid, nullable
  - `business_id` string, uuid, required
  - `session_id` string, uuid, required
  - `last_message` LastMessageOut
    - `status` string, required
    - `content` string, required
    - `no_reply` boolean
  - `timestamp` string, date-time, required
  - `messages` unknown[], required
    - unknown
  - `created` string, date-time, required
  - `instructions` unknown[], nullable
    - unknown
  - `custom_instructions` unknown[], nullable
    - unknown
  - `kind` string
  - `consumer` ChatConsumerOut
    - `id` string, uuid, required
    - `nickname` string, nullable
    - `phone_number` string, nullable
  - `refine_reviewed` boolean
  - `refine_verdict` string, nullable

## Other responses

- `401`: Missing or invalid credentials.
- `403`: The business hit the free plan's sandbox-chat limit, or the plan does not include the REST API.
- `404`: The resource, or the business named in the request, does not exist.
- `422`: Validation Error
- `default`: Unexpected error.

---

[API](https://skmtc.dev/izap/apis/izap-api.md) · [All operations](https://skmtc.dev/izap/apis/izap-api/llms.txt) · [OpenAPI document](https://skmtc.dev/izap/apis/izap-api/revisions/e6358c8bf5e9?raw)
