Migrate to data stream APIedit

Converts an index alias to a data stream.

POST /_data_stream/_migrate/my-logs

Requestedit

POST /_data_stream/_migrate/<alias>

Prerequisitesedit

Path parametersedit

<alias>

(Required, string) Name of the index alias to convert to a data stream. The alias must meet the following criteria:

  • The alias must have a write index.
  • All indices for the alias have a @timestamp field mapping of a date or date_nanos field type.
  • The alias must not have any filters.
  • The alias must not use custom routing.

If successful, the request removes the alias and creates a data stream with the same name. The alias’s indices become hidden backing indices for the stream. The alias’s write index becomes the stream’s write index.