Skip to main content
Glama

session_reconcile

Compare declared session exit actions against actual receipt log data to uncover unverified claims and unreported privileged actions, then finalize the session.

Instructions

Close a bound session and reconcile what you DECLARE you did against what the receipt log shows you actually did (check-out; willow-gate seam Phase 4 / H3).

exit_declaration is the reconciled subset of the entry header — tools (the willow-gate CLASSES you exercised: read/write/execute/admin), plus your self-scored pass_count/fail_count/drift/state_hash. The server sources the ground truth from ReceiptLog (every gated call that actually ran since your check-in — you cannot feed it), classifies those tools, and diffs:

  • claimed_not_done — a class you claim you used that NO receipt backs;

  • beyond_entry / done_not_claimed — a privileged class the receipts show you used that you did not pre-declare / did not report. clean is false if any privileged discrepancy is found; read-level over/under- reporting is surfaced but never fails the session. The session is DROPPED after this call (its per-call nonce set is freed), so verify_call for it then fails.

Requires a live session bound to your app_id (call session_bind first); returns {error} if there is none. This RECONCILES and records — it never blocks a handoff, so run session_handoff_write / handoff_write_v4 as usual alongside it.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
app_idYes
session_idYes
exit_declarationYes
Behavior5/5

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

With no annotations, the description carries full burden and does so thoroughly: it discloses that the session is DROPPED after the call, that it reads ground truth from ReceiptLog, and that `clean` is false on privileged discrepancies while read-level over/under-reporting does not fail the session. This is far beyond minimal.

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 long but each section adds necessary detail: a one-line summary, the declaration structure, the diff categories, and side effects/prerequisites. It is front-loaded and uses bullets for readability, though it could be tightened slightly.

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

Completeness4/5

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

For a tool with no annotations and no output schema, the description covers prerequisites, side effects, return conditions, and relationship to handoff tools. It doesn't enumerate the full response object, but `clean` and `{error}` are disclosed. This is a highly complete description for a complex utility.

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 description coverage is 0%, but the description thoroughly explains `exit_declaration`, listing its expected fields (`tools`, `pass_count`, `fail_count`, `drift`, `state_hash`) and the willow-gate classes. It also references `app_id` and live-session binding. App_id and session_id are self-explanatory from their names, so the only complex param is well-covered.

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 explicitly states 'Close a bound session and reconcile what you DECLARE you did against what the receipt log shows you actually did', which is a specific verb+resource. It distinguishes itself from siblings like session_bind, session_read, and handoff tools by describing its unique role in the session lifecycle.

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?

It states a prerequisite ('call session_bind first') and provides complementary guidance ('run session_handoff_write / handoff_write_v4 as usual alongside it'). It also clarifies it 'never blocks a handoff,' but it does not explicitly discuss alternatives or when-not-to-use scenarios, so a 4 is warranted.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/rudi193-cmd/willow-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server