Skip to main content
Glama
cloudsmithy

Easysearch MCP Server

by cloudsmithy

aggregate

Perform aggregation queries on search indices to group, analyze, and summarize data using terms, averages, date histograms, and multi-level aggregations.

Instructions

执行聚合查询 参数: index: 索引名称 aggs: 聚合定义 query: 过滤条件(可选) size: 返回文档数(默认 0,仅返回聚合结果) 示例 - 分组统计: aggregate("orders", aggs={ "by_status": {"terms": {"field": "status"}} }) 示例 - 多级聚合: aggregate("orders", aggs={ "by_category": { "terms": {"field": "category"}, "aggs": { "avg_price": {"avg": {"field": "price"}} } } }) 示例 - 日期直方图: aggregate("logs", aggs={ "by_day": { "date_histogram": { "field": "@timestamp", "calendar_interval": "day" } } })

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
indexYes
aggsYes
queryNo
sizeNo

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/cloudsmithy/easysearch-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server