DELETE
/
api
/
v2
/
data-sources
Delete data sources
curl --request DELETE \
  --url https://app.livechatai.com/api/v2/data-sources \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "agentId": "clx1234567890abcdef",
  "source": "WEBSITE",
  "id": "ds_1234567890",
  "ids": [
    "ds_1234567890",
    "ds_0987654321"
  ]
}'
{
  "status": "success",
  "data": {
    "message": "2 items deleted successfully",
    "agentId": "clx1234567890abcdef",
    "source": "TEXT",
    "deleted": [
      "ds_1234567890",
      "ds_0987654321"
    ],
    "notFound": []
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Data source deletion details

agentId
string
required

Unique identifier of the agent

Example:

"clx1234567890abcdef"

source
enum<string>
required

Type of data source to delete

Available options:
WEBSITE,
TEXT,
QA,
PDF,
DOCX,
IMAGE
Example:

"WEBSITE"

id
string

Unique identifier of the data source item to delete (for single deletion)

Example:

"ds_1234567890"

ids
string[]

Array of unique identifiers for bulk deletion

Example:
["ds_1234567890", "ds_0987654321"]

Response

Data sources deleted successfully

status
string
Example:

"success"

data
object