Get aliases
- GET /_cat/aliases/{name}
- GET /_cat/aliases
Get the cluster's index aliases, including filter and routing information. This API does not return data stream aliases.
IMPORTANT: CAT APIs are only intended for human consumption using the command line or the Kibana console. They are not intended for use by applications. For application consumption, use the aliases API.
- Index privileges:
view_index_metadata
Path Parameters
-
nameName | Nameoptional -
A comma-separated list of aliases to retrieve. Supports wildcards (
*). To retrieve all aliases, omit this parameter or use*or_all.Leave it out to use
/_cat/aliases.
Query Parameters
-
hCatAliasesColumns A comma-separated list of columns names to display. It supports simple wildcards.
Supported values include:
alias(ora): The name of the alias.index(ori,idx): The name of the index the alias points to.filter(orf,fi): The filter applied to the alias.routing.index(orri,routingIndex): Index routing value for the alias.routing.search(orrs,routingSearch): Search routing value for the alias.is_write_index(orw,isWriteIndex): Indicates if the index is the write index for the alias.
-
Values:
aliasaindexiidxfilterffirouting.indexriroutingIndexrouting.searchrsroutingSearchis_write_indexwisWriteIndex -
sNames List of columns that determine how the table should be sorted. Sorting defaults to ascending and can be changed by setting
:ascor:descas a suffix to the column name.-
expand_wildcardsstring ExpandWildcards · default: all The type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. It supports comma-separated values, such as
open,hidden.Supported values include:
all: Match any data stream or index, including hidden ones.open: Match open, non-hidden indices. Also matches any non-hidden data stream.closed: Match closed, non-hidden indices. Also matches any non-hidden data stream. Data streams cannot be closed.hidden: Match hidden data streams and hidden indices. Must be combined withopen,closed, orboth.none: Wildcard expressions are not accepted.
-
Values:
allopenclosedhiddennone -
master_timeoutstring Duration · default: 30s The period to wait for a connection to the master node. If the master node is not available before the timeout expires, the request fails and returns an error. To indicated that the request should never timeout, you can set it to
-1.
Response
Response Type: AliasesRecord
-
aliasstring -
alias name
-
indexstring IndexName -
index alias points to
-
filterstring -
filter
-
routing.indexstring -
index routing
-
routing.searchstring -
search routing
-
is_write_indexstring -
write index