> ## Documentation Index
> Fetch the complete documentation index at: https://docs.botcadence.com/llms.txt
> Use this file to discover all available pages before exploring further.

# List conversations

> Get paginated conversation history for a project

Returns conversation history for a project with pagination and optional filters.

## Authentication

<ParamField header="X-API-Key" type="string" required>
  Project API key for this organization and project. Format: `bot_live_…`
</ParamField>

## Path parameters

<ParamField path="organization_id" type="string" required>
  Organization ID. Must match the API key.
</ParamField>

<ParamField path="project_id" type="string" required>
  Project ID. Must match the API key.
</ParamField>

## Query parameters

<ParamField query="skip" type="integer" default="0">
  Number of records to skip.
</ParamField>

<ParamField query="limit" type="integer" default="20">
  Page size. Range: `1`–`100`.
</ParamField>

<ParamField query="filters" type="string">
  JSON filter object, for example `{"status":"completed"}`.
</ParamField>

<ParamField query="sort" type="string">
  JSON sort object, for example `{"start_time":-1}`.
</ParamField>

<ParamField query="unique" type="boolean" default="false">
  When `true`, returns only the latest conversation per unique caller.
</ParamField>

## Response

<ResponseField name="items" type="array" required>
  Conversation records for the current page.
</ResponseField>

<ResponseField name="pagination" type="object" required>
  Pagination metadata (`total`, `page`, `page_size`, `total_pages`, `has_next`, `has_prev`).
</ResponseField>

## Errors

<ResponseField name="401" type="Unauthorized">
  Missing, invalid, or revoked API key.
</ResponseField>

<ResponseField name="403" type="Forbidden">
  API key is not authorized for this organization or project.
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl -G "https://backend.botcadence.com/organizations/ORG_ID/projects/PROJECT_ID/conversations" \
    -H "X-API-Key: bot_live_YOUR_KEY" \
    --data-urlencode "skip=0" \
    --data-urlencode "limit=20" \
    --data-urlencode 'filters={"status":"completed"}' \
    --data-urlencode 'sort={"start_time":-1}'
  ```

  ```javascript JavaScript theme={null}
  const params = new URLSearchParams({
    skip: "0",
    limit: "20",
    filters: JSON.stringify({ status: "completed" }),
    sort: JSON.stringify({ start_time: -1 }),
  });

  const response = await fetch(
    `https://backend.botcadence.com/organizations/${organizationId}/projects/${projectId}/conversations?${params}`,
    { headers: { "X-API-Key": process.env.BOTCADENCE_API_KEY } }
  );
  ```

  ```python Python theme={null}
  import json
  import os
  import requests

  response = requests.get(
      f"https://backend.botcadence.com/organizations/{organization_id}/projects/{project_id}/conversations",
      headers={"X-API-Key": os.environ["BOTCADENCE_API_KEY"]},
      params={
          "skip": 0,
          "limit": 20,
          "filters": json.dumps({"status": "completed"}),
          "sort": json.dumps({"start_time": -1}),
      },
  )
  ```
</RequestExample>

<ResponseExample>
  ```json 200 theme={null}
  {
    "status": "success",
    "message": "Conversation history retrieved successfully",
    "data": {
      "items": [
        {
          "_id": "665f1a2b3c4d5e6f7a8b9c0d",
          "status": "completed",
          "conversation_type": "outbound",
          "phone_number": "+14155552671",
          "start_time": "2026-07-21T15:04:00Z",
          "duration_seconds": 142
        }
      ],
      "pagination": {
        "total": 86,
        "page": 1,
        "page_size": 20,
        "total_pages": 5,
        "has_next": true,
        "has_prev": false
      }
    },
    "status_code": 200
  }
  ```
</ResponseExample>
