query: { text_query: { fields: ["coupon_id"], search_phrase: "xmas" } }Example: (coupon_id contains "xmas" OR description contains "xmas")
query: { text_query: { fields: ["description", "coupon_id"], search_phrase: "xmas" } }Example: (description contains "holiday" AND description contains "bojo")
query: { text_query: { fields: ["description"], search_phrase: "holiday bogo" } }
Property | Type | Constraints | Description |
---|---|---|---|
fields
|
[String] | mandatory=true, minItems=1, nullable=false | The document fields the search phrase has to match against. |
search_phrase
|
String | mandatory=true, nullable=false | A search phrase, which may consist of multiple terms. |