Skip to main content
POST
/
v1
/
voiceai
/
knowledge-base
/
text
Create Text Document
curl --request POST \
  --url https://api.example.com/v1/voiceai/knowledge-base/text \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "text": "<string>"
}
'
{
  "id": "<string>",
  "name": "<string>",
  "folder_path": [
    {
      "id": "<string>",
      "name": "<string>"
    }
  ]
}

Authorizations

x-api-key
string
header
required

API key for programmatic access

Body

application/json

Request body for POST /knowledge-base/text endpoint. Creates a knowledge base document containing the provided text.

text
string
required

Text content to be added to the knowledge base.

name
string | null

A custom, human-readable name for the document.

Minimum string length: 1
parent_folder_id
string | null

If set, the created document or folder will be placed inside the given folder.

Response

Successful Response

Response model for all document creation endpoints (URL, text, file). Returns the created document's ID, name, and folder path.

id
string
required

The ID of the created document

name
string
required

The name of the created document

folder_path
KnowledgeBaseFolderPathSegmentResponseModel · object[]

The folder path segments leading to this entity, from root to parent folder.