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

# Conversation Details and Summary API

[Back to API List](https://koreai.mintlify.site/ai-for-service/apis/automation/api-list)

To fetch conversation details and summary between the bot and user, or the user and agent. Supports pagination via `skip/offset` and `limit` parameters.

| Field | Value |
| - | - |
| **Method** | POST |
| **Endpoint** | `https://{{host}}/api/public/bot/{{botId}}/conversationDetails` |
| **Content Type** | `application/json` |
| **Authorization** | `auth: {{JWT}}` See [How to generate the JWT Token](https://koreai.mintlify.site/ai-for-service/apis/automation/api-introduction.md#generating-the-jwt-token). |
| **API Scope** | App Builder: Chat History |

## Path Parameters

| Parameter | Required | Description |
| - | - | - |
| `host` | Required | Environment URL, for example, `https://platform.kore.ai`. |
| `botId` | Required | Bot identifier or Stream identifier. Access it from the [General Settings](https://koreai.mintlify.site/ai-for-service/app-settings.md) page of the bot. |

## Sample Request

```bash theme={null}
curl --location --request POST 'https://platform.kore.ai/api/public/bot/st-86exxx8d-7021-5f2b-bf6c-8a1xxxxxb0/conversationDetails' \
--header 'auth: {{JWT_TOKEN}}' \
--header 'Content-Type: application/json' \
--data-raw '{
"callId":"00001",
"isSummaryRequired":true
}'
```

## Request Body Parameters

| Parameter | Required | Description |
| - | - | - |
| `skip/offset` | Optional | The number of messages to skip. |
| `limit` | Optional | The number of messages to show per page. |
| `sessionId/callId` | Required | Unique session ID or call ID to fetch conversation details. The `callId` refers to the external call identifier provided by third-party agent desktops. |
| `conversationId` | Optional | Unique identifier for the conversation. This field is required when `sessionId` or `call ID` is not entered. Use either `sessionId` or `conversationId`; if both `sessionId` and `conversationId` are provided, `sessionId` takes precedence. |
| `lang` | Optional | The language in which the conversation summary should be returned. |
| `isSummaryRequired` | Optional | Whether to include an auto-generated summary: `true` to include, `false` (default) to exclude. |

> [!NOTE]
>
> If the session ID is available, the call ID isn't mandatory and vice versa. If both are present, the session ID is used.

## Sample Response

```json expandable=true theme={null}
{
   "conversationInfo": {
       "userId": "u-c8c61885-85bb-xxxx-xxxx-6fd4a97c58f9",
       "callId": "9eb6c49e-f647*******c-cc207e3a6080",
       "sessionStartTime": "2023-08-07T11:18:10.195Z",
       "agentHandOffTime": "2023-08-07T11:18:11.304Z",
       "userDetails": {
           "firstName": "",
           "lastName": "",
           "phoneNumber": null
       },
       "currentTask": "null",
       "sessionId": "64d0d2f2bxxxxxxxxa566d08"
   },
   "conversationFlow": [
       {
           "status": "completedTask",
           "messageStoreId": "xxx",
           "taskName": "ConnectToAgent"
       }
   ],
   "conversationHistory": [
       {
           "type": "outgoing",
           "status": "pending",
           "createdOn": "2023-08-07T11:18:10.337Z",
           "components": [
               {
                   "cT": "text",
                   "data": {
                       "text": "Agent transfer initiated"
                   }
               }
           ]
       }
   ],
   "summary": {
       "ConversationSummary": "agent will need to get an agent on the line to help customer with that.",
       "time": "2023-08-09T06:53:18.579Z"
   }
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.