You're viewing version 3.3 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 Alias Exists API
Introduced 1.0
Checks if an alias exists.
Endpoints
HEAD /_alias/<alias>
HEAD /<index>/_alias/<alias>
Path parameters
The following table lists the available path parameters. All path parameters are required.
| Parameter | Data type | Description |
|---|---|---|
<alias> | String | Comma-separated list or wildcard expression of alias names to check. |
<index> | String | Comma-separated list or wildcard expression of index names used to limit the request. |
Query parameters
The following table lists the available query parameters. All query parameters are optional.
| Parameter | Data type | Description |
|---|---|---|
expand_wildcards | String | Type of index that wildcard expressions can match. Supports comma-separated values. Valid values are all, open, closed, hidden, and none. Default is all. |
ignore_unavailable | Boolean | Whether to ignore unavailable indexes. Default is false. |
local | Boolean | Whether to return information from the local node only instead of from the cluster manager node. Default is false. |
Response codes
The API returns one of the following response codes.
| Response code | Description |
|---|---|
200 | Indicates that all specified aliases exist. |
404 | Indicates that one or more specified aliases do not exist. |
Example requests
HEAD /_alias/2030response = client.indices.exists_alias(
name = "2030"
)Related documentation
For more information about index aliases, see Index aliases.