API reference
Content
Create, read, update, and delete content items within a knowledge base. Creating a content item triggers automatic chunking and embedding in the background.
Base path
https://api.kognita.ai/api/v1/knowledge-bases/{id}/contents/v1/knowledge-bases/{id}/contentsList contents
/v1/knowledge-bases/{id}/contentsCreate content (text)
/v1/knowledge-bases/{id}/contents/fileUpload content (file)
/v1/knowledge-bases/{id}/contents/{contentId}Get content
/v1/knowledge-bases/{id}/contents/{contentId}Update content
/v1/knowledge-bases/{id}/contents/{contentId}Delete content
List contents
/api/v1/knowledge-bases/{id}/contentsPath parameters
| Parameter | Type | Description |
|---|---|---|
idrequired | string(path) | Knowledge base ID. |
Query parameters
| Parameter | Type | Description |
|---|---|---|
page | integer(query) | Page number. Default: 1. |
limit | integer(query) | Items per page. Default: 20. Max: 100. |
Responses
{
"success": true,
"data": [
{
"id": "cnt_xyz789",
"contentChunk": "Kognita is a managed knowledge-base API...",
"createdAt": "2026-05-08T10:00:05Z",
"metadata": {}
}
],
"total": 42
}Create content (text)
/api/v1/knowledge-bases/{id}/contentsIngests a text string into the knowledge base. Kognita runs chunking and embedding asynchronously; the API returns as soon as the content record is persisted.
Path parameters
| Parameter | Type | Description |
|---|---|---|
idrequired | string(path) | Knowledge base ID. |
Request body
| Parameter | Type | Description |
|---|---|---|
textrequired | string(body) | The text to ingest. |
metadata | object(body) | Optional arbitrary key/value metadata stored alongside the content and returned in search results. |
{
"text": "Kognita provides hybrid search over your data.",
"metadata": { "source": "docs", "version": "2" }
}Responses
{
"success": true,
"data": {
"id": "cnt_xyz789"
}
}Upload content (file)
/api/v1/knowledge-bases/{id}/contents/fileUploads a file to be parsed and ingested into the knowledge base. Kognita extracts text from the file, then runs chunking and embedding asynchronously.
Path parameters
| Parameter | Type | Description |
|---|---|---|
idrequired | string(path) | Knowledge base ID. |
Request body
Send as multipart/form-data.
| Parameter | Type | Description |
|---|---|---|
filerequired | binary(body) | The file to upload. |
Responses
{
"success": true,
"data": {
"id": "cnt_xyz789"
}
}Get content
/api/v1/knowledge-bases/{id}/contents/{contentId}Path parameters
| Parameter | Type | Description |
|---|---|---|
idrequired | string(path) | Knowledge base ID. |
contentIdrequired | string(path) | Content item ID. |
Responses
{
"success": true,
"data": {
"id": "cnt_xyz789",
"contentChunk": "Kognita provides hybrid search over your data.",
"createdAt": "2026-05-08T10:00:05Z",
"metadata": {}
}
}Update content
/api/v1/knowledge-bases/{id}/contents/{contentId}Replaces the text of a content item and triggers re-embedding of all its chunks.
Path parameters
| Parameter | Type | Description |
|---|---|---|
idrequired | string(path) | Knowledge base ID. |
contentIdrequired | string(path) | Content item ID. |
Request body
| Parameter | Type | Description |
|---|---|---|
textrequired | string(body) | Replacement text. All existing chunks will be deleted and regenerated. |
metadata | object(body) | Optional metadata to replace existing metadata. |
Responses
{ "success": true }Delete content
/api/v1/knowledge-bases/{id}/contents/{contentId}Permanently deletes a content item and all its chunks and embeddings.
Path parameters
| Parameter | Type | Description |
|---|---|---|
idrequired | string(path) | Knowledge base ID. |
contentIdrequired | string(path) | Content item ID. |
Responses
{ "success": true }