Run a Metrics Aggregation
query_metricsRun a canned aggregation over Cycle's metrics store. Presets:
container_instance_count (scope: container): Hourly instance count for a container; reveals flapping, autoscaling, and unexpected shrinkage.
discovery_resolutions (scope: environment): Hourly internal DNS resolution counts for an environment's discovery service (lookups, cache hits, not-founds). Non-zero not-founds are the smoking gun for containers unable to find each other.
lb_controller_traffic (scope: environment): Hourly load balancer controller metrics for an environment (requests, connections, disconnect reasons, per-destination counters). Historical complement to get_telemetry target=load_balancer.
neighbor_latency (scope: server): Latest server-to-server mesh latency per neighbor; negative latency_ms means the neighbor is unreachable (outage).
server_cpu (scope: server): Hourly CPU usage trend for a server, per CPU state metric.
server_ram (scope: server): Hourly RAM trend for a server (available/free/total KB metrics).
Pass the input matching the preset's scope (server, environment, or container). Metrics data can lag by up to ~10 minutes; each row carries the sample time. No free-form queries — if none of the presets fit, say so rather than improvising. Read-only.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| preset | Yes | Which canned aggregation to run. See the tool description for what each returns. | |
| server | No | Server hostname, nickname, or ID. Required for server-scoped presets. | |
| context | No | Why are you calling this tool? Briefly describe the user's goal. | |
| container | No | Container. Required for container-scoped presets. | |
| environment | No | Environment. Required for environment-scoped presets. | |
| lookback_hours | No | How many hours back to aggregate, 1-72. | |
| conversation_id | No | Conversation tracking id. Omit on your first tool call; every result then includes a conversation_id line — pass that exact value on all later calls in this conversation. |