Skip to main content
Glama

fetch_session_inbox

Retrieve a newest-first page of unread inbox messages for your host session or T3 thread, with optional message bodies and read-state handling for replies.

Instructions

Return one newest-first page across registrations matching your host/session tag or T3 thread. Use machine-derived host and session_id, with t3_thread when known; never guess from an agent name. Each receipt includes project_key and agent_name for replies and acknowledgements. Defaults: unread_only:true, mark_read:true, include_bodies:false, limit:20. To drain, include bodies; stop when fewer than limit messages return (default 20, capped at 1000), repeating only after a full page. With mark_read:false or unread_only:false, this is a bounded preview, not a drain. The CLI swarmail inbox --session discovers identity and drains without mailbox arguments. Session identity selects inboxes and is not authentication: whoever can reach the server can read any mailbox.

Input Schema

NameRequiredDescriptionDefault
hostYesHost tag, such as claude, codex, cursor, devin, opencode, grok or agy.
limitNoPositive page size; default 20, capped at 1000.
mark_readNoDefault true. False previews without marking receipts read.
t3_threadNoYour T3 thread ID when known; includes older provider registrations in that thread.
session_idYesYour native host session ID from its shell variable or registration.
unread_onlyNoDefault true. False gives a bounded page including read receipts.
include_bodiesNoInclude each body_md; default false.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.3.0

TDQS

A4/5.0
Behavior3/5

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

Annotations declare readOnlyHint=false and non-idempotent, which the description correctly corroborates by disclosing that mark_read defaults to true and thus mutates state. It also adds the important security caveat that session identity selects inboxes but is not authentication. It stops short of stating what a repeated call returns or how ordering interacts with mark_read, so it is additive but not rich.

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, then defaults, then drain protocol, then the security note. Sentences are dense and nearly all earn their place, though the defaults recap overlaps with the schema and could be trimmed.

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, the description still tells the agent what a receipt contains (project_key, agent_name, body_md), how many to expect per page, when to stop looping, and which sibling tools handle replies and acknowledgements. That is enough to invoke and iterate correctly.

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 coverage is 100%, so the schema already documents all seven parameters; baseline is 3. The description adds the drain stop condition (fewer than limit returned, cap 1000) and the agent-name warning, but mostly restates defaults already in the schema.

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?

States a specific verb and resource: returns one newest-first page of receipts scoped to the caller's host/session tag or T3 thread. The scope distinction from a generic inbox listing is implied by 'registrations matching your host/session tag', but no sibling (e.g. fetch_inbox) is named for direct contrast.

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 positive and negative guidance: use machine-derived host and session_id, add t3_thread when known, and 'never guess from an agent name'. It also defines the alternative modes — draining by including bodies and looping until a short page, versus a bounded preview when mark_read:false or unread_only:false — and points to the CLI equivalent that needs no arguments.

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