Skip to main content
Glama

resolve_messages

Permanently acknowledge selected messages to remove them from the pending queue after partial handling, preventing already-handled mail from reappearing in new sessions.

Instructions

Permanently resolve (ack) specific messages so they leave your pending queue for good (v2.12.0).

When to use: PARTIAL handling — you've actioned some of your mail but not all ("I did these, not those"). For the common "I've handled everything I just drained" path, prefer get_messages(status='pending', ack=true) which drains AND resolves in one call. Resolving is the durable, session-INDEPENDENT counterpart to reading: read is a per-session observation (a fresh terminal re-sees prior-session-read mail so handovers don't drop unfinished work); resolved is a permanent "handled, archive it" that the pending filter honors, so an already-handled message never re-floods a new session.

Behavior: sets resolved_at=now() for the eligible ids, in one transaction. Does NOT mark messages read (orthogonal plane) and does NOT delete them — they remain in status='all'/'history'/'resolved'. Idempotent: re-resolving, unknown ids, or ineligible ids are silently skipped (reflected in the returned counts). Scope: you can resolve mail addressed to YOU (recipient-resolve), OR an obligation/message YOU sent to a recipient that is NOT a registered agent (sender-resolve) — a human (e.g. a person you owe an answer) has no token, so without this such mail could never be cleared and the pending-on-a-human lane would be write-only. You can NEVER resolve mail addressed to a real agent — that stays the recipient's to clear. The dispatcher binds your token to agent_name, so there is no impersonation path. Edge: the non-agent check is evaluated at resolve time, so if a human recipient later REGISTERS as an agent the sender can no longer resolve it — note names that case so a legitimate zero doesn't read as a failure.

Returns: { success: true, agent, resolved_ids: string[], resolved_count, requested_count, blocked_by_recipient_registration: {id,to_agent}[], note }. resolved_count < requested_count when some ids were already resolved, unknown, not yours, or (per blocked_by_recipient_registration) sent by you to a recipient that has since become a registered agent.

Errors: AUTH_FAILED (token missing/mismatched), VALIDATION (empty/oversized id list), RATE_LIMITED.

Input Schema

NameRequiredDescriptionDefault
agent_nameYesYour agent name — you can resolve mail addressed to you, or an obligation you sent to a non-agent recipient
agent_tokenNoYour agent token (from register_agent response). Optional here — also resolvable from RELAY_AGENT_TOKEN env or X-Agent-Token header.
message_idsYesThe message ids to permanently resolve (ack). Only ids addressed to you are affected; unknown/foreign ids are silently skipped.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / agent_name / description
      Previous value: -"Your agent name (the recipient; only your own mail can be resolved)"New value: +"Your agent name — you can resolve mail addressed to you, or an obligation you sent to a non-agent recipient"
  2. First observed

TDQS

A4.8/5.0
Behavior5/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 so thoroughly: single transaction, sets resolved_at=now(), does NOT mark read, does NOT delete (still visible under all/history/resolved), idempotent silent-skip behavior, and the registration-timing edge case that can block sender-resolve. It also lists auth binding, return shape, and error codes, covering the safety and mutation profile an agent needs.

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?

Front-loaded with purpose and when-to-use, then Behavior, Returns, and Errors in a clean progression. It is dense and long, but the scope rules and edge cases justify most of the length; a few sentences (e.g. the impersonation reassurance) could be trimmed without loss.

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?

For a mutation tool with no annotations and no output schema, the description supplies the return structure inline (resolved_ids, resolved_count, requested_count, blocked_by_recipient_registration, note) and enumerates the errors (AUTH_FAILED, VALIDATION, RATE_LIMITED). Nothing an agent needs to invoke it correctly is missing.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description adds real meaning beyond the schema: agent_name is token-bound with "no impersonation path," and message_ids eligibility (unknown/foreign ids silently skipped) is explained rather than just listed. It stops short of adding syntax-level detail for message_ids, so a 4 rather than a 5.

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

Purpose5/5

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

States a specific verb+resource ("Permanently resolve (ack) specific messages") plus the effect ("so they leave your pending queue for good"). It explicitly distinguishes itself from the sibling get_messages path that drains and resolves in one call, and from the orthogonal read/observation plane. An agent can tell exactly what this does and what it is not.

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

Usage Guidelines5/5

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

Gives explicit when-to-use: "PARTIAL handling — you've actioned some of your mail but not all," and names the alternative for the common case: prefer get_messages(status='pending', ack=true). It also lays out scope rules (recipient-resolve vs sender-resolve, never resolve mail addressed to a real agent), which is exactly the kind of when/when-not routing a strong definition provides.

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