The field capabilities API allows to retrieve the capabilities of fields among multiple indices.
field_caps(fields = NULL, index = NULL, body = list(), raw = FALSE,
asdf = FALSE, ...)
A list of fields to compute stats for. optional
Index name, one or more
Query, either a list or json
(logical) Get raw JSON back or not
(logical) If TRUE
, use jsonlite::fromJSON()
to parse JSON directly to a data.frame if possible. If FALSE
(default), list output is given.
Curl args passed on to httr::POST()
https://www.elastic.co/guide/en/elasticsearch/reference/current/search-field-caps.html
# NOT RUN {
connect()
field_caps(body = '{ "fields": ["speaker"] }', index = "shakespeare")
# }
Run the code above in your browser using DataLab