Skip to main content
Glama

sage_messages_receive

Receive and atomically claim one bounded local message batch for a session, using a caller-generated token to replay the exact batch after lost responses without claiming later messages.

Instructions

Receive and atomically claim one bounded local message batch for this opaque MCP claimant session. Reusing the same receive_token replays the exact original batch after a lost response and never claims later messages. A fresh token does not make prior work look cleared: the response separately includes own_claimed_unfinished for this session and the payload-free claimed_elsewhere recovery surface for sibling sessions. Concurrent runtimes sharing one agent identity can transfer ownership explicitly with sage_message_handoff. SAGE signs one exact read acknowledgement per returned message before presenting it. Each item keeps the authoritative exact sender in sender_agent; from_display_name, from_registered_name, and provider-derived labels are optional presentation metadata. Display/provider labels can change, legacy rows use the current display-name compatibility fallback for a missing saved registered name, and no label authorizes work. Answer returned work only with sage_message_reply; a failed reply is not authorization to create a substitute request with sage_message_send.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNo
receive_tokenYesCaller-generated token for this exact receive attempt

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv11.17.4

TDQS

A4.9/5.0
Behavior5/5

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

No annotations are provided, so the description carries the full behavioral burden. It discloses atomic claim semantics, replay behavior, session isolation, signing of exactly one read acknowledgement per message, sender accuracy rules, and the non-authoritative nature of display labels. This is exceptionally transparent for a complex tool.

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

Conciseness5/5

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

Though lengthy, every sentence carries unique, critical information. The primary purpose is front-loaded, and the follow-on sentences address replay, sessions, handoff, signing, sender fields, and reply routing. Each sentence earns its place; there is no filler or redundancy.

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?

Given the complexity, 50% schema coverage, and no output schema, the description is remarkably complete. It explains token semantics, session isolation, sibling handoff, response contents (own_claimed_unfinished and claimed_elsewhere), signing, sender fields, and correct reply routing. An agent has enough to invoke it correctly without missing critical behavior.

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?

The schema covers 50% (receive_token has a description, limit does not). The description adds rich meaning for receive_token: it is caller-generated, replaying the original batch, and a fresh token does not clear prior work. It implies limit controls the 'bounded' batch size, but does not explicitly restate the default/max. Since token semantics are heavily elaborated, this justify a 4.

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?

The description gives a specific verb ('receive and atomically claim') and a precise resource ('one bounded local message batch for this opaque MCP claimant session'). It clearly differentiates from siblings like sage_inbox and sage_message_history by emphasizing claiming, token replay, and session scope. An agent can tell exactly what this does.

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?

The description gives explicit usage context: reusing receive_token replays the original batch, a fresh token does not clear prior work, and ownership transfer is handled via sage_message_handoff. It also states that returned work must be answered with sage_message_reply, not sage_message_send. This is clear when-to-use and when-not-to-use guidance.

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