POST
/
api
/
v2
/
data-sources
/
url
Create a URL data source
curl --request POST \
  --url https://app.livechatai.com/api/v2/data-sources/url \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "url": "https://www.example.com/about-us",
  "agentId": "clx1234567890abcdef"
}'
{
  "status": "success",
  "data": {
    "message": "Added successfully",
    "item": {
      "id": "ds_1234567890",
      "source": "WEBSITE",
      "isGeneratedByAI": false
    }
  }
}

Authorizations

Authorization
string
header
required

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

Body

application/json

Details for the URL data source.

url
string
required

URL of the webpage to be added as data source

Example:

"https://www.example.com/about-us"

agentId
string
required

Unique identifier of the agent

Example:

"clx1234567890abcdef"

Response

URL data source created successfully

status
string
Example:

"success"

data
object