Get the async search status

  • GET /_async_search/status/{id}
Auth

Get the status of a previously submitted async search request given its identifier, without retrieving search results. If the Elasticsearch security features are enabled, the access to the status of a specific async search is restricted to:

  • The user or API key that submitted the original async search request.
  • Users that have the monitor cluster privilege or greater privileges.

Required privileges

Cluster privileges monitor

Path parameters

id string required

A unique identifier for the async search.

Query parameters

keep_alive string · default: 5d

The length of time that the async search needs to be available. Ongoing async searches and any saved search results are deleted after this period.

Response

application/json
id string
is_partial boolean required

When the query is no longer running, this property indicates whether the search failed or was successfully completed on all shards. While the query is running, is_partial is always set to true.

is_running boolean required

Indicates whether the search is still running or has completed.

Note

If the search failed after some shards returned their results or the node that is coordinating the async search dies, results may be partial even though is_running is false.

expiration_time union oneOf

Indicates when the async search will expire.

One of: string or number
expiration_time_in_millis number required
start_time union oneOf
One of: string or number
start_time_in_millis number required
completion_time union oneOf

Indicates when the async search completed. It is present only when the search has completed.

One of: string or number
completion_time_in_millis number
error object
type string required

The type of error

reason union string nullable

A human-readable explanation of the error, in English.

One of: string
stack_trace string

The server stack trace. Present only if the error_trace=true parameter was sent with the request.

caused_by object
Same fields as error
root_cause object[]
Same fields as error
suppressed object[]
Same fields as error
_shards object required

The number of shards that have run the query so far.

failed number required

The number of shards the operation or search attempted to run on but failed.

successful number required

The number of shards the operation or search succeeded on.

total number required

The number of shards the operation or search will run on overall.

failures object[]
index string
node string
reason object required
type string required

The type of error

reason union string nullable

A human-readable explanation of the error, in English.

One of: string
stack_trace string

The server stack trace. Present only if the error_trace=true parameter was sent with the request.

caused_by object
Same fields as reason in failures
root_cause object[]
Same fields as reason in failures
suppressed object[]
Same fields as reason in failures
shard number
status string
primary boolean
skipped number
_clusters object

Metadata about clusters involved in the cross-cluster search. It is not shown for local-only searches.

skipped number required
successful number required
total number required
running number required
partial number required
failed number required
details map string to object
<string> object
status enum required
Values: running successful partial skipped failed
indices string required
took number
timed_out boolean required
_shards object
Same fields as _shards
failures object[]
Same fields as failures in _shards
completion_status number

If the async search completed, this field shows the status code of the search. For example, 200 indicates that the async search was successfully completed. 503 indicates that the async search was completed with an error.