Skip to main content
Glama

aom__CountEvents

Counts events and alerts in segmented intervals for a specified project and time range, with optional metadata filters, query type, and sorting.

Instructions

[AOM] 该接口用于分段统计指定条件下的事件、告警。

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": {
      "project_id": "<project_id>",
      "step": "<step>",
      "time_range": "<time_range>"
    },
    "name": "aom__CountEvents"
  }
}

Input Schema

NameRequiredDescriptionDefault
sortNo返回列表的排序方式,可以为空。
stepYes统计步长。毫秒数,例如一分钟则填写为60000。
typeNo查询类型。type=active_alert代表查询活动告警,type=history_alert代表查询历史告警。不传或者传其他值则返回指定查询条件的所有信息。
searchNo模糊查询匹配字段,可以为空。如果值不为空,可以模糊匹配metadata字段中的必选字段的值。
project_idYes租户从IAM申请到的projectid,一般为32位字符串。
time_rangeYestimeRange用于指标查询时间范围,主要用于解决客户端时间和服务端时间不一致情况下,查询最近N分钟的数据。另可用于精确查询某一段时间的数据。
metadata_relationNo查询条件组合,可以为空。

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.0

TDQS

C2.9/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are supplied, so the description carries the full behavioral burden, yet it discloses nothing about read-only vs mutating behavior, permissions, rate limits, or result shape. The single useful hint is that output is bucketed by a step, which is left unstated in this sentence.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single short sentence with the resource and operation front-loaded and no filler. It is efficient, though its brevity is also the source of the missing guidance rather than a sign of completeness.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With 7 parameters, 3 required, no annotations, and no output schema, the definition should say what the statistics look like (counts per time bucket, per event type) and how step interacts with time_range. None of that is present, leaving an agent to guess at the return shape.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so every parameter is already documented in the schema, including step, type, search, and metadata_relation. The description's phrase '指定条件' gestures at those filters but adds no syntax, defaults, or combination guidance beyond the schema, so baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description names a specific verb and resource: '分段统计' (bucketed/segmented statistics) over '事件、告警' (events and alerts). An agent can tell this is an aggregation endpoint rather than a listing endpoint. It does not differentiate itself from siblings such as aom__ListEvents, so it lands at 4 rather than 5.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no statement of when to prefer this over aom__ListEvents or the other event-listing siblings, and no prerequisites or exclusions. The only implied usage is 'when you need counts', which the reader must infer from the word 统计.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools