Reindex into another index
reindexCopy documents between indices with optional query filtering and script transformations. Asynchronous operation returns a task id to track completion.
Instructions
Copy documents between indices. Asynchronous: returns a task id at once and the copy is still running on return — poll it with GET _tasks/.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | No | Query DSL selecting which documents to copy. Omit to copy all. | |
| script | No | Transform each document while copying | |
| destIndex | Yes | Destination index, created if absent | |
| sourceIndex | Yes | Source index |