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

# Delete Customer Data API

<Badge icon="arrow-left" color="gray">[Back to API List](/ai-for-service/apis/automation/api-list)</Badge>

Deletes customer data from the platform.

The deletion doesn't proceed if the requested user is:

* An account owner or belongs to one or more accounts.
* The bot owner or co-developer for one or more bots.

| Property          | Value                                                                                                                              |
| ----------------- | ---------------------------------------------------------------------------------------------------------------------------------- |
| **Method**        | DELETE                                                                                                                             |
| **Endpoint**      | `https://{{host}}/api/public/bot/eraseUsersData`                                                                                   |
| **Content Type**  | `application/json`                                                                                                                 |
| **Authorization** | `auth: {{JWT}}` — See [How to generate the JWT Token](/ai-for-service/apis/automation/api-introduction/#generating-the-jwt-token). |
| **API Scope**     | App Builder: Not Applicable; Admin Console: Profile Management > Delete Users Data                                                 |

## Path Parameters

| Parameter | Description                                              |
| --------- | -------------------------------------------------------- |
| `host`    | Environment URL, for example, `https://platform.kore.ai` |

## Sample Request

```bash theme={null}
curl -X DELETE \
  'https://{{host}}/api/public/bot/eraseUsersData' \
  --header 'Content-Type: application/json' \
  --header 'auth: {{YOUR_JWT_ACCESS_TOKEN}}' \
  --data '{
    "userIds": ["u-xxxxxxxx-xxxx-xxx-xxxx-xxxxxxxxxxx"],
    "botIds": ["st-xxxxxxxx-xxxx-xxx-xxxx-xxxxxxxxxxxx"],
    "RemoveDataFromAllBots": true
  }'
```

## Body Parameters

| Parameter                          | Description                                                                                                                                    |
| ---------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- |
| `userIds`                          | Array of user IDs to delete. Accepts Kore-generated user IDs (email or `u-id`), `channel_user_id`, or both `channel_id` and `channel_user_id`. |
| `botIds`                           | Array of AI Agent IDs from which to delete user data. Effective only when `RemoveDataFromAllBots` is `false`.                                  |
| `RemoveDataFromAllBots` (optional) | If `true`, deletes user data from all AI Agents in the organization and ignores `botIds`. Defaults to `false`.                                 |

<Note>
  To check the execution status of this request, use the [Delete Customer Data Status API](/ai-for-service/apis/automation/delete-customer-data-status).
</Note>

## Sample Response

```json theme={null}
{
  "requestId": "eud-123",
  "status": "in-progress"
}
```
