search
Query Elasticsearch using DSL to retrieve, highlight, and script fields for specified indices, enabling precise data extraction and analysis.
Instructions
Perform an Elasticsearch search with the provided query DSL, highlighting, and script fields
Input Schema
Name | Required | Description | Default |
---|---|---|---|
index | Yes | Name of the Elasticsearch index to search | |
queryBody | Yes | Complete Elasticsearch query DSL object (can include query, size, from, sort, etc.) | |
scriptFields | No | Script fields to evaluate and include in the response |
Input Schema (JSON Schema)
{
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false,
"properties": {
"index": {
"description": "Name of the Elasticsearch index to search",
"minLength": 1,
"type": "string"
},
"queryBody": {
"additionalProperties": {},
"description": "Complete Elasticsearch query DSL object (can include query, size, from, sort, etc.)",
"type": "object"
},
"scriptFields": {
"additionalProperties": {
"additionalProperties": false,
"properties": {
"script": {
"additionalProperties": false,
"properties": {
"lang": {
"default": "painless",
"description": "Script language (defaults to painless)",
"type": "string"
},
"params": {
"additionalProperties": {},
"description": "Optional parameters for the script",
"type": "object"
},
"source": {
"description": "Painless script source code",
"minLength": 1,
"type": "string"
}
},
"required": [
"source"
],
"type": "object"
}
},
"required": [
"script"
],
"type": "object"
},
"description": "Script fields to evaluate and include in the response",
"type": "object"
}
},
"required": [
"index",
"queryBody"
],
"type": "object"
}