Run a search application search
Beta
Generate and run an Elasticsearch query that uses the specified query parameteter and the search template associated with the search application or default template. Unspecified template parameters are assigned their default values if applicable.
Path parameters
-
name
string Required The name of the search application to be searched.
Query parameters
-
typed_keys
boolean Determines whether aggregation names are prefixed by their respective types in the response.
Responses
-
200 application/json
Hide response attributes Show response attributes object
-
took
number Required The number of milliseconds it took Elasticsearch to run the request. This value is calculated by measuring the time elapsed between receipt of a request on the coordinating node and the time at which the coordinating node is ready to send the response. It includes:
- Communication time between the coordinating node and data nodes
- Time the request spends in the search thread pool, queued for execution
- Actual run time
It does not include:
- Time needed to send the request to Elasticsearch
- Time needed to serialize the JSON response
- Time needed to send the response to a client
-
timed_out
boolean Required If
true
, the request timed out before completion; returned results may be partial or empty. -
_shards
object Required Additional properties are allowed.
Hide _shards attributes Show _shards attributes object
-
failed
number Required -
successful
number Required -
total
number Required -
failures
array[object] Hide failures attributes Show failures attributes object
-
index
string -
node
string -
reason
object Required Additional properties are allowed.
Hide reason attributes Show reason attributes object
-
type
string Required The type of error
-
reason
string A human-readable explanation of the error, in English.
-
stack_trace
string The server stack trace. Present only if the
error_trace=true
parameter was sent with the request. -
caused_by
object Additional properties are allowed.
-
root_cause
array[object] Additional properties are allowed.
-
suppressed
array[object] Additional properties are allowed.
-
-
shard
number Required -
status
string
-
-
skipped
number
-
-
hits
object Required Additional properties are allowed.
Hide hits attributes Show hits attributes object
-
hits
array[object] Required Hide hits attributes Show hits attributes object
-
_index
string Required -
_id
string _score
number | string | null -
_explanation
object Additional properties are allowed.
Hide _explanation attributes Show _explanation attributes object
-
description
string Required -
details
array[object] Required Additional properties are allowed.
-
value
number Required
-
-
fields
object Hide fields attribute Show fields attribute object
-
*
object Additional properties Additional properties are allowed.
-
-
highlight
object Hide highlight attribute Show highlight attribute object
-
*
array[string] Additional properties
-
-
inner_hits
object matched_queries
array[string] | object -
_nested
object Additional properties are allowed.
-
_ignored
array[string] -
ignored_field_values
object Hide ignored_field_values attribute Show ignored_field_values attribute object
-
*
array[object] Additional properties Additional properties are allowed.
-
-
_shard
string -
_node
string -
_routing
string -
_source
object Additional properties are allowed.
-
_rank
number -
_seq_no
number -
_primary_term
number -
_version
number -
sort
array[number | string | boolean | null] A field value.
-
max_score
number | string | null
-
aggregations
object -
_clusters
object Additional properties are allowed.
Hide _clusters attributes Show _clusters attributes object
-
skipped
number Required -
successful
number Required -
total
number Required -
running
number Required -
partial
number Required -
failed
number Required -
details
object Hide details attribute Show details attribute object
-
*
object Additional properties Additional properties are allowed.
Hide * attributes Show * attributes object
-
status
string Required Values are
running
,successful
,partial
,skipped
, orfailed
. -
indices
string Required -
took
number Time unit for milliseconds
-
timed_out
boolean Required -
_shards
object Additional properties are allowed.
Hide _shards attributes Show _shards attributes object
-
failed
number Required -
successful
number Required -
total
number Required -
failures
array[object] Additional properties are allowed.
-
skipped
number
-
-
failures
array[object]
-
-
-
-
fields
object Hide fields attribute Show fields attribute object
-
*
object Additional properties Additional properties are allowed.
-
-
max_score
number -
num_reduce_phases
number -
profile
object Additional properties are allowed.
Hide profile attribute Show profile attribute object
-
shards
array[object] Required Hide shards attributes Show shards attributes object
-
aggregations
array[object] Required Hide aggregations attributes Show aggregations attributes object
-
breakdown
object Required Additional properties are allowed.
-
description
string Required -
type
string Required -
debug
object Additional properties are allowed.
-
children
array[object]
-
-
cluster
string Required -
dfs
object Additional properties are allowed.
Hide dfs attributes Show dfs attributes object
-
statistics
object Additional properties are allowed.
Hide statistics attributes Show statistics attributes object
-
type
string Required -
description
string Required -
time
string A duration. Units can be
nanos
,micros
,ms
(milliseconds),s
(seconds),m
(minutes),h
(hours) andd
(days). Also accepts "0" without a unit and "-1" to indicate an unspecified value. -
breakdown
object Required Additional properties are allowed.
-
debug
object -
children
array[object]
-
-
knn
array[object] Additional properties are allowed.
-
-
fetch
object Additional properties are allowed.
Hide fetch attributes Show fetch attributes object
-
type
string Required -
description
string Required -
time_in_nanos
number Time unit for nanoseconds
-
breakdown
object Required Additional properties are allowed.
Hide breakdown attributes Show breakdown attributes object
-
load_source
number -
load_source_count
number -
load_stored_fields
number -
load_stored_fields_count
number -
next_reader
number -
next_reader_count
number -
process_count
number -
process
number
-
-
debug
object Additional properties are allowed.
Hide debug attributes Show debug attributes object
-
stored_fields
array[string] -
fast_path
number
-
-
children
array[object] Additional properties are allowed.
-
-
id
string Required -
index
string Required -
node_id
string Required -
searches
array[object] Required Hide searches attributes Show searches attributes object
-
collector
array[object] Required -
query
array[object] Required -
rewrite_time
number Required
-
-
shard_id
number Required
-
-
-
pit_id
string -
_scroll_id
string -
suggest
object Hide suggest attribute Show suggest attribute object
-
terminated_early
boolean
-
curl \
--request POST http://api.example.com/_application/search_application/{name}/_search \
--header "Authorization: $API_KEY" \
--header "Content-Type: application/json" \
--data '"{\n \"params\": {\n \"query_string\": \"my first query\",\n \"text_fields\": [\n {\"name\": \"title\", \"boost\": 5},\n {\"name\": \"description\", \"boost\": 1}\n ]\n }\n}"'
{
"params": {
"query_string": "my first query",
"text_fields": [
{"name": "title", "boost": 5},
{"name": "description", "boost": 1}
]
}
}