---
title: "Chat Or Question And Answer"
method: POST
path: "/teams/{team_id}/bots/{bot_id}/chat"
---

# Chat Or Question And Answer

`POST /teams/{team_id}/bots/{bot_id}/chat`

## Request

- Base URL: `https://api.docsbot.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.docsbot.ai/teams/{team_id}/bots/{bot_id}/chat`
- Auth: none declared

## Path parameters

- `team_id` string, required
- `bot_id` string, required

## Request body

- Ask
  - `question` string, required
  - `history` array[]
    - string[]
  - `format` 'markdown' | 'text' | 'html', nullable
  - `full_source` boolean, nullable
  - `metadata` object, nullable
  - `testing` boolean, nullable
  - `autocut` union
    - boolean
    - integer
  - `context_items` integer

## Response `200`

Successful Response

- union
  - AskResponse
    - `answer` string, required
    - `couldAnswer` boolean, nullable
    - `sources` Source[], required
      - `type` string, required
      - `title` string, nullable, required
      - `url` string, nullable, required
      - `fileId` string, nullable
      - `page` integer, nullable, required
      - `content` string, nullable
      - `used` boolean, nullable
    - `history` array[]
      - string[]
    - `id` string, required
  - Error
    - `error` string, required

## Other responses

- `422`: Validation Error

---

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