Change document retrieval inclusion
curl --request PATCH \
--url https://app.hookie.ai/admin/api/data-workspace/documents/{document_id}/inclusion \
--header 'Content-Type: application/json' \
--data '
{
"included": true,
"expected_version": 2
}
'const options = {
method: 'PATCH',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({included: true, expected_version: 2})
};
fetch('https://app.hookie.ai/admin/api/data-workspace/documents/{document_id}/inclusion', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.hookie.ai/admin/api/data-workspace/documents/{document_id}/inclusion"
payload = {
"included": True,
"expected_version": 2
}
headers = {"Content-Type": "application/json"}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){}Data workspace
Change document retrieval inclusion
Requires write access. Inclusion changes use their own revision, separate from content_version. Stale revisions or deleting documents return 409. Exclusion preserves the original document.
PATCH
/
admin
/
api
/
data-workspace
/
documents
/
{document_id}
/
inclusion
Change document retrieval inclusion
curl --request PATCH \
--url https://app.hookie.ai/admin/api/data-workspace/documents/{document_id}/inclusion \
--header 'Content-Type: application/json' \
--data '
{
"included": true,
"expected_version": 2
}
'const options = {
method: 'PATCH',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({included: true, expected_version: 2})
};
fetch('https://app.hookie.ai/admin/api/data-workspace/documents/{document_id}/inclusion', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.hookie.ai/admin/api/data-workspace/documents/{document_id}/inclusion"
payload = {
"included": True,
"expected_version": 2
}
headers = {"Content-Type": "application/json"}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){}