Knowledge Bases
Manage knowledge bases that agents can reference during calls. Creating a knowledge base is a two-step process:- Create the knowledge base (name + description only).
- Add sources — upload files, paste text, or crawl URLs. Each source is indexed independently and has its own
status.
List Knowledge Bases
Parameters
Query parameters:| Parameter | Type | Default | Description |
|---|---|---|---|
name | string | — | Filter by name (case-insensitive substring match) |
limit | integer | 50 | 1–100 |
offset | integer | 0 | Pagination offset |
data (array of knowledge base objects), pagination, and meta.
cURL
Get Knowledge Base
Returnsdata (knowledge base object) and meta.
Create Knowledge Base
Create an empty knowledge base. Add content via Add Document Source or Add Web Source after creation.Parameters
Request body:| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Display name for the knowledge base |
description | string | No | Optional description |
cURL
data (knowledge base object, status: "ready") and meta.
Update Knowledge Base
Update the name or description. Only included fields are changed. To update content, add or delete sources.Parameters
Request body:| Field | Type | Description |
|---|---|---|
name | string | New display name |
description | string | New description |
cURL
Delete Knowledge Base
Permanently deletes the knowledge base, all its sources, and removes it from Ultravox. Agents that reference this knowledge base will no longer have access to it.List Sources
List all sources attached to a knowledge base. Source statuses are synced in real-time. Poll this endpoint every 5–10 seconds while any source hasstatus: "scanning" to track indexing progress.
Add Document Source
Upload a file (PDF, TXT, DOCX, or Markdown) as a source. The file is base64-encoded in the request body. Maximum file size: 50 MB.Parameters
Request body:| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Display name for this source |
description | string | No | Optional description |
file | object | Yes | File to upload (see below) |
file object:
| Field | Type | Description |
|---|---|---|
filename | string | File name including extension (e.g. policy.pdf) |
data | string | Base64-encoded file content |
content_type | string | MIME type: application/pdf, text/plain, application/vnd.openxmlformats-officedocument.wordprocessingml.document, text/markdown |
cURL
data (source object with initial status: "scanning") and meta. Poll List Sources until status becomes ready or failed.
Add Web Source
Crawl one or more URLs and index their content as a source. The crawler follows links up tomax_depth levels.
Parameters
Request body:| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Display name for this source |
description | string | No | Optional description |
urls | string[] | Yes | One or more URLs to crawl |
max_depth | integer | No | Link-follow depth. 0 = page only, 1 = one level of links (default). Max 3. |
cURL
data (source object with initial status: "scanning") and meta. Poll List Sources until status becomes ready or failed.
Delete Source
Remove a source from a knowledge base. The indexed content for this source is permanently deleted from Ultravox.Knowledge Base Object
| Field | Type | Description |
|---|---|---|
id | UUID | Knowledge base ID |
name | string | Display name |
description | string | Optional description |
status | string | ready — available to agents; creating — being set up |
language | string | Content language (e.g. en-US) |
created_at | datetime | When the knowledge base was created |
updated_at | datetime | Last updated |
Source Object
| Field | Type | Description |
|---|---|---|
id | UUID | Source ID |
kb_id | UUID | Parent knowledge base ID |
name | string | Display name |
description | string | Optional description |
kind | string | document (file upload) or web (URL crawl) |
status | string | pending — queued; scanning — indexing in progress; ready — fully indexed; failed — indexing error |
created_at | datetime | When the source was added |
updated_at | datetime | Last updated |

