---
title: "Recursive Chunker"
method: POST
path: "/v1/chunk/recursive"
---

# Recursive Chunker

`POST /v1/chunk/recursive`

Chunk the given text using the Recursive Chunker.

## Request body

- RecursiveChunkerREQ — Data to pass to the Recursive Character Text Splitter.
  - `text` union, required — The input text or list of texts to be chunked.
    - string
    - string[]
  - `tokenizer_or_token_counter` string
  - `chunk_size` integer
  - `rules` object
  - `min_characters_per_chunk` integer
  - `return_type` string

## Response `200`

Successful Response: A list of recursive chunk objects.

- RecursiveChunkSchema[] — A list containing recursive chunk objects, each detailing a segment of the original text and its recursion level.
  - `text` string — The actual text content of the chunk.
  - `start_index` integer — The starting character index of the chunk within the original input text.
  - `end_index` integer — The ending character index (exclusive) of the chunk within the original input text.
  - `token_count` integer — The number of tokens in this specific chunk, according to the tokenizer used.
  - `level` integer — The level of this chunk in the recursive splitting process.

## Changes

- **2025-04-06** `2d174e4e5a5a` — 1 info
  - the request property `chunk_size` became optional
- **2025-04-06** `a9d5b6b90675` — 5 breaking, 1 warning, 5 info
  - the response property `items/end_index` became optional for the status `200`
  - the response property `items/level` became optional for the status `200`
  - the response property `items/start_index` became optional for the status `200`
  - the response property `items/text` became optional for the status `200`
  - …7 more
- **2025-04-06** `678e90630336` — 4 info
  - removed the non-success response with the status `401`
  - removed the non-success response with the status `422`
  - removed the non-success response with the status `500`
  - added the required property `items/level` to the response with the `200` status
- **2025-04-06** `c791be50601b` — 2 breaking, 6 warning, 3 info
  - added the new required request property `args`
  - the response's body type changed from no type to `array` for status `200`
  - deleted the `header` request parameter `authorization`
  - removed the request property `chunk_size`
  - …7 more

[Change history](https://skmtc.dev/feyninc/apis/chonkie-api/changes/v1/chunk/recursive/post.md)

---

[API](https://skmtc.dev/feyninc/apis/chonkie-api.md) · [All operations](https://skmtc.dev/feyninc/apis/chonkie-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/feyninc/chonkie-api/revisions/2d174e4e5a5a/schema)
