Add a web-link document
curl --request POST \
--url https://api.pineyard.ai/documents/web-link \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"url": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({name: '<string>', url: '<string>'})
};
fetch('https://api.pineyard.ai/documents/web-link', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.pineyard.ai/documents/web-link"
payload = {
"name": "<string>",
"url": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"id": "<string>",
"name": "<string>",
"description": "<string>",
"type": "<string>",
"status": "<string>",
"sourceUrl": "<string>",
"fileSize": 123,
"mimeType": "<string>",
"externalId": "<string>",
"createdAt": "<string>",
"updatedAt": "<string>"
}Agent documents
Add a web-link document
POST
/
documents
/
web-link
Add a web-link document
curl --request POST \
--url https://api.pineyard.ai/documents/web-link \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"url": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({name: '<string>', url: '<string>'})
};
fetch('https://api.pineyard.ai/documents/web-link', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.pineyard.ai/documents/web-link"
payload = {
"name": "<string>",
"url": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"id": "<string>",
"name": "<string>",
"description": "<string>",
"type": "<string>",
"status": "<string>",
"sourceUrl": "<string>",
"fileSize": 123,
"mimeType": "<string>",
"externalId": "<string>",
"createdAt": "<string>",
"updatedAt": "<string>"
}Required scope:
knowledge.editAuthorizations
Your API key, e.g. pk_live_xxxxxxxxxxxxxxxxxxxxxxxx.
Body
application/json

