mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-02-06 21:18:31 +00:00
Returns information about settings, aliases, warmers, and mappings. Basically returns the IndexMetadata. This new endpoint replaces the /{index}/_alias|_aliases|_mapping|_mappings|_settings|_warmer|_warmers and /_alias|_aliases|_mapping|_mappings|_settings|_warmer|_warmers endpoints whilst maintaining the same response formats. The only exception to this is on the /_alias|_aliases|_warmer|_warmers endpoint which will now return a section for 'aliases' or 'warmers' even if no aliases or warmers exist. This backwards compatibility change is documented in the reference docs. Closes #4069
30 lines
1.0 KiB
Plaintext
30 lines
1.0 KiB
Plaintext
[[indices-get-index]]
|
|
== Get Index
|
|
|
|
The get index API allows to retrieve information about one or more indexes.
|
|
|
|
[source,js]
|
|
--------------------------------------------------
|
|
$ curl -XGET 'http://localhost:9200/twitter/'
|
|
--------------------------------------------------
|
|
|
|
The above example gets the information for an index called `twitter`. Specifying an index,
|
|
alias or wildcard expression is required.
|
|
|
|
The get index API can also be applied to more than one index, or on
|
|
all indices by using `_all` or `*` as index.
|
|
|
|
[float]
|
|
=== Filtering index information
|
|
|
|
The information returned by the get API can be filtered to include only specific features
|
|
by specifying a comma delimited list of features in the URL:
|
|
|
|
[source,js]
|
|
--------------------------------------------------
|
|
$ curl -XGET 'http://localhost:9200/twitter/_settings,_mappings'
|
|
--------------------------------------------------
|
|
|
|
The above command will only return the settings and mappings for the index called `twitter`.
|
|
|
|
The available features are `_settings`, `_mappings`, `_warmers` and `_aliases`. |