Skip to main content
POST
/
parse
/
text
/
Parse Text
curl --request POST \
  --url https://rag-prod.studio.lyzr.ai/v3/parse/text/ \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '{
  "data": [
    {
      "text": "string",
      "source": "string",
      "extra_info": {}
    }
  ],
  "chunk_size": 1000,
  "chunk_overlap": 100
}'
{
  "documents": [
    {
      "id_": "1140ba4e-e5f5-4999-a5d6-4263f2c48b57",
      "embedding": {},
      "metadata": {
        "source": "<string>",
        "chunked": true
      },
      "text": "string",
      "excluded_embed_metadata_keys": [
        "<string>"
      ],
      "excluded_llm_metadata_keys": [
        "<string>"
      ]
    }
  ]
}

Authorizations

x-api-key
string
header
required

Body

application/json
data
object[]
required

Array of text objects to be parsed.

Example:
[
{
"text": "string",
"source": "string",
"extra_info": {}
}
]
chunk_size
integer
required

Size of the chunks for text splitting.

Example:

1000

chunk_overlap
integer
required

Overlap between consecutive text chunks.

Example:

100

Response

Text successfully parsed and documents returned.

documents
object[]

List of processed document chunks.