Skip to main content
Glama

Get agent events

get_agent_events

Poll a subagent's buffered event log to track progress, filter to tool events, and resume from a sequence. Return a compact summary digest for quick status checks.

Instructions

Buffered normalized event log for an agent, for background polling. Reliable floor for progress. The response identifies the agent by both name and agent_id; prefer the name in conversation. The response always includes currentSequence (the true latest sequence for this agent, even when events is empty) so you can seek straight to "now" instead of bisecting since. Pass limit to cap how many events come back in one call (applied after types filtering); hasMore says whether more remain past nextSequence. types keeps only the listed event types — raw logs are mostly tiny message.delta text chunks, so filtering to e.g. tool.start/tool.end cuts the noise. coalesce (default false) merges consecutive message.delta events into one on read, without changing storage. summary: true returns a compact digest (state, tool counts, last few tool calls, tail of the latest message) instead of the raw log — prefer it for progress checks; pass since with it to scope the digest to events after a previous currentSequence, so repeat calls only report what's new.

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": {
      "agent": "<agent>"
    },
    "name": "get_agent_events"
  }
}

Input Schema

NameRequiredDescriptionDefault
agentYes
limitNoCaps events returned in this call
sinceNo
typesNoKeep only events of these types
summaryNoReturn a compact digest (state, tool counts, last few tool calls, tail of the latest message) instead of the raw log. Prefer this for progress checks.
coalesceNoMerge consecutive message.delta events into one on read (default false; does not change what's stored)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv0.4.0
    • addedInput schema / properties / coalesce
      Added value: +{
      +  "description": "Merge consecutive message.delta events into one on read (default false; does not change what's stored)",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / summary
      Added value: +{
      +  "description": "Return a compact digest (state, tool counts, last few tool calls, tail of the latest message) instead of the raw log. Prefer this for progress checks.",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / types
      Added value: +{
      +  "description": "Keep only events of these types",
      +  "items": {
      +    "enum": [
      +      "thread.started",
      +      "message.delta",
      +      "tool.start",
      +      "tool.end",
      +      "approval.requested",
      +      "turn.completed",
      +      "error"
      +    ],
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
  2. First observedv0.1.0

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does substantial work: it guarantees `currentSequence` is always present even when `events` is empty, explains `hasMore`/`nextSequence` semantics, states `limit` is applied after `types` filtering, and clarifies `coalesce` is a read-time view that does not alter storage. Missing are failure modes, permission requirements, or any cost/latency characteristics.

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?

The description is dense but front-loaded with purpose and the reliable-floor guarantee before parameter detail. It is longer than average and some sentences restate what the schema descriptions already say (`coalesce`, `summary`), which is mild redundancy, but no sentence is pure filler.

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

Completeness5/5

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

With no output schema and six parameters, the description compensates by documenting return shape (`name`, `agent_id`, `events`, `currentSequence`, `nextSequence`, `hasMore`) and the digest alternative. An agent can call this correctly and know how to resume polling without additional information.

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

Parameters5/5

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

Against 67% schema coverage, the description adds real meaning for every parameter: `since` is scoped as "events after a previous currentSequence," `limit` is ordered relative to `types` filtering, `coalesce` has a default and a non-persistence guarantee, and `summary` enumerates the digest contents. The interaction between `since`, `summary`, and `currentSequence` is spelled out in a way the schema cannot express.

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 opening line states a specific resource and scope: a buffered, normalized event log for one agent, framed for background polling. It is clear what the tool returns, but it never contrasts itself with adjacent readers like get_agent_result or get_agent_diff, so an agent must infer which reader to pick from context alone.

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

Usage Guidelines4/5

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

Guidance is concrete: use it for background polling, prefer `summary: true` for progress checks, filter `types` to `tool.start`/`tool.end` to cut delta noise, and pair `since` with `summary` so repeat calls report only what's new. It stops short of naming a sibling tool as an alternative or stating when this tool should not be used.

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