Files

879 B
Raw Permalink Blame History

layout, title, parent, nav_order
layout title parent nav_order
default IDs Term-level queries 40

IDs query

Use the ids query to search for documents with one or more specific document ID values in the _id field. For example, the following query requests documents with the IDs 34229 and 91296:

GET shakespeare/_search
{
  "query": {
    "ids": {
      "values": [
        34229,
        91296
      ]
    }
  }
}

{% include copy-curl.html %}

Parameters

The query accepts the following parameter.

Parameter Data type Description
values Array of strings The document IDs to search for. Required.
boost Floating-point A floating-point value that specifies the weight of this field toward the relevance score. Values above 1.0 increase the field’s relevance. Values between 0.0 and 1.0 decrease the field’s relevance. Default is 1.0.