Skip to main content
POST
/
chatbots
/
{chatbotId}
/
knowledge-base
/
data-sources
/
links
Add link
curl --request POST \
  --url https://api.chatling.ai/v2/chatbots/{chatbotId}/knowledge-base/data-sources/links \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "links": [
    "<string>"
  ],
  "exclude_classes": [
    "<string>"
  ],
  "exclude_ids": [
    "<string>"
  ],
  "exclude_header": true,
  "exclude_footer": true,
  "exclude_nav": true
}
'
{
    "status": "success",
    "data": {
        "links_added": 105,
        "duplicate_links_removed": []
    }
}

Documentation Index

Fetch the complete documentation index at: https://docs.chatling.ai/llms.txt

Use this file to discover all available pages before exploring further.

Request parameters

Path

chatbotId
string
required
The chatbot ID.

Body

Array of webpage links to add to the knowledge base.
exclude_classes
string[]
Exclude sections of webpages based on their HTML class names.
exclude_ids
string[]
Exclude sections of webpages based on their HTML IDs.
exclude_header
boolean
Exclude header tags.
Exclude footer tags.
exclude_nav
boolean
Exclude nav tags.

Response

status
string
The status of the request. Will be success if the request was successful, otherwise error.
data
object
{
    "status": "success",
    "data": {
        "links_added": 105,
        "duplicate_links_removed": []
    }
}