mongo_aggregate
Execute MongoDB aggregation pipelines to transform and analyze data within a collection.
Instructions
Run an aggregation pipeline on a MongoDB collection.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"collection": "<collection>",
"pipeline": "<pipeline>"
},
"name": "mongo_aggregate"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| database | No | ||
| pipeline | Yes | JSON string representing an array of pipeline stages. | |
| collection | Yes | ||
| connectionId | No | Id of the mongodb connection to use. Optional when only one mongodb connection is configured. |