Add website pages
curl --request POST \
--url https://api.meetdarwin.ai/v1/knowledge/sources \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"urls": [
"<string>"
]
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({urls: ['<string>']})
};
fetch('https://api.meetdarwin.ai/v1/knowledge/sources', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.meetdarwin.ai/v1/knowledge/sources"
payload = { "urls": ["<string>"] }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"object": "knowledge_import",
"added": 123,
"skipped": 123,
"rejected": [
"<string>"
]
}{
"object": "knowledge_import",
"added": 123,
"skipped": 123,
"rejected": [
"<string>"
]
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}Knowledge
Add website pages
Requires the knowledge:write scope.
POST
/
knowledge
/
sources
Add website pages
curl --request POST \
--url https://api.meetdarwin.ai/v1/knowledge/sources \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"urls": [
"<string>"
]
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({urls: ['<string>']})
};
fetch('https://api.meetdarwin.ai/v1/knowledge/sources', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.meetdarwin.ai/v1/knowledge/sources"
payload = { "urls": ["<string>"] }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"object": "knowledge_import",
"added": 123,
"skipped": 123,
"rejected": [
"<string>"
]
}{
"object": "knowledge_import",
"added": 123,
"skipped": 123,
"rejected": [
"<string>"
]
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}{
"type": "https://docs.meetdarwin.ai/api-reference/errors#insufficient_scope",
"title": "<string>",
"status": 0,
"code": "insufficient_scope",
"detail": "<string>",
"request_id": "req_8m2k4p0q1x7z9c3v5b6n",
"param": "<string>"
}Authorizations
A secret key (dk_live_…). Scopes: conversations:read, contacts:read, contacts:write, meetings:read, analytics:read, events:read, webhooks:write, knowledge:read, knowledge:write, agent:read, agent:write, experiments:read, experiments:write, privacy:write, chat:write.
Headers
Retry safely: the first response is replayed for 24 hours (not for streamed answers).
Maximum string length:
255Body
application/json
Required array length:
1 - 100 elementsMaximum string length:
2000