Returns one knowledge base. Poll it after Create knowledge base or Add sources to see when ingestion has finished.
Request#
| Path parameter | Type | Required | Description |
|---|---|---|---|
id |
string | Yes | The knowledge base ID, starting with knowledge_base_. |
Example request#
curl https://api.tried.com.au/get-knowledge-base/knowledge_base_9f060d81a4d8df9b04ca6d12 \
-H "Authorization: Bearer $TRIED_API_KEY"const res = await fetch(
"https://api.tried.com.au/get-knowledge-base/knowledge_base_9f060d81a4d8df9b04ca6d12",
{ headers: { Authorization: `Bearer ${process.env.TRIED_API_KEY}` } },
);
const kb = await res.json();import os, requests
res = requests.get(
"https://api.tried.com.au/get-knowledge-base/knowledge_base_9f060d81a4d8df9b04ca6d12",
headers={"Authorization": f"Bearer {os.environ['TRIED_API_KEY']}"},
)
kb = res.json()Response#
200 OK
{
"knowledge_base_id": "knowledge_base_9f060d81a4d8df9b04ca6d12",
"knowledge_base_name": "Clinic FAQ",
"status": "complete",
"knowledge_base_sources": [
{
"source_id": "source_92055d142a2829e5c8e77a9f",
"type": "text",
"title": "Opening hours",
"url": null,
"content_url": "https://api.tried.com.au/get-knowledge-base-source-content/knowledge_base_9f060d81a4d8df9b04ca6d12/source_92055d142a2829e5c8e77a9f"
},
{
"source_id": "source_21ce463cc228d0ea2a439493",
"type": "url",
"title": "https://example.com.au/pricing",
"url": "https://example.com.au/pricing",
"content_url": "https://api.tried.com.au/get-knowledge-base-source-content/knowledge_base_9f060d81a4d8df9b04ca6d12/source_21ce463cc228d0ea2a439493"
}
],
"enable_auto_refresh": true,
"last_refreshed_timestamp": 1760832000000,
"chunk_size": 800,
"chunk_overlap": 100,
"auto_add_pages": false,
"crawl_roots": []
}| Field | Type | Description |
|---|---|---|
knowledge_base_id |
string | Starts with knowledge_base_. |
status |
string | in_progress while sources are being ingested, complete when the last batch finished, error when any source in the last batch failed. |
knowledge_base_sources |
array | Sources, oldest first. |
knowledge_base_sources[].source_id |
string | Starts with source_. |
knowledge_base_sources[].type |
string | document (uploaded or synced file), text or url. |
knowledge_base_sources[].title |
string | File name, snippet title, or the URL for URL sources. Synced documents end with the provider in brackets, for example FAQ (notion). |
knowledge_base_sources[].url |
string or null | The page URL for URL sources and the provider link for synced documents. null otherwise. |
knowledge_base_sources[].content_url |
string | Authenticated link to the source's extracted text. See Get source content. |
enable_auto_refresh |
boolean | Whether URL sources are re-fetched about once a day. |
last_refreshed_timestamp |
integer or null | Unix ms when ingestion last finished, for any reason. null before the first run finishes. |
chunk_size |
integer | Target characters per chunk. |
chunk_overlap |
integer | Characters shared between neighbouring chunks. |
auto_add_pages |
boolean | Whether a refresh crawls crawl_roots for new pages. |
crawl_roots |
array of strings | Site URLs crawled on refresh when auto_add_pages is on. |
The response does not show a status per source.
Errors#
| Status | When |
|---|---|
401 |
Missing or invalid API key. |
403 |
The key's IP allowlist or scopes reject the request. This route needs the kb scope. |
404 |
Knowledge base <id> not found. |
429 |
Rate limit exceeded. See Rate limits. |
See Errors for the body format.
Retell compatibility#
Same path and method as Retell. The object adds chunk_size, chunk_overlap, auto_add_pages and crawl_roots, and has no max_chunk_size or min_chunk_size. Missing knowledge bases return 404 (Retell uses 422).