Link Search Menu Expand Document Documentation Menu

You're viewing version 3.1 of the OpenSearch documentation. This version is no longer maintained. For the latest version, see the current documentation. For information about OpenSearch version maintenance, see Release Schedule and Maintenance Policy.

Index template exists

The index template exists API operation is used to verify whether an index template exists.

Endpoints

HEAD /_index_template/<template-name>

Path parameters

All path parameters are required.

Parameter Type Description
template-name String The name of the index template to check for existence.

Query parameters

All parameters are optional.

Parameter Type Description
local Boolean If true, the request does not retrieve the state from the cluster manager node. Default is false.
cluster_manager_timeout Time Specifies how long to wait for a connection to the cluster manager node. Default is 30s.

Example request

HEAD /_index_template/my-template

Example responses

If the template exists, the response returns a success code:

200 OK

If the template does not exist, the response returns a failure code:

404 Not Found
350 characters left

Have a question? .

Want to contribute? or .