---
title: "Create Text Document"
method: POST
path: "/v1/convai/knowledge-base/text"
tags: ["Agents Platform"]
---

# Create Text Document

`POST /v1/convai/knowledge-base/text`

Create a knowledge base document containing the provided text.

## Headers

- `xi-api-key` string, nullable — Your API key. This is required by most endpoints to access our API programmatically. You can view your xi-api-key using the 'Profile' tab on the website.

## Request body

- BodyCreateTextDocumentV1ConvaiKnowledgeBaseTextPost
  - `text` string, required — Text content to be added to the knowledge base.
  - `name` string, nullable — A custom, human-readable name for the document.
  - `parent_folder_id` string, nullable — If set, the created document or folder will be placed inside the given folder.

## Response `200`

Successful Response

- AddKnowledgeBaseResponseModel
  - `id` string, required
  - `name` string, required
  - `folder_path` KnowledgeBaseFolderPathSegmentSummaryResponseModel[] — The folder path segments leading to this entity, from root to parent folder.
    - `id` string, required

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/elevenlabs/apis/elevenlabs-api-documentation.md) · [All operations](https://skmtc.net/elevenlabs/apis/elevenlabs-api-documentation/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/elevenlabs/elevenlabs-api-documentation/versions/e77a0a530a82/schema)
