Skip to main content
Glama

session_reconcile

Reconcile declared session actions against actual receipt log, detect unbacked claims or undeclared privileged usage, then drop the session. Returns clean status and discrepancies.

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
Behavior1/5

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

The description clearly states that the session is DROPPED after this call and per-call nonce sets are freed, yet the annotations specify destructiveHint=false. This directly contradicts the annotation, so the behavioral transparency score must be 1 despite the otherwise rich detail about ReceiptLog and classification behavior.

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 organized: purpose, exit_declaration structure, reconciliation logic, side effects, prerequisites, and handoff relationship. It is front-loaded with the core action. The reference to 'willow-gate seam Phase 4 / H3' adds minor noise but does not undermine usability.

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 complex tool with no output schema, the description covers requirements, the exit_declaration shape, reconciliation behaviors, error on missing session, and the post-condition that the session is dropped. It does not fully spell out the successful response shape, but it provides enough context for an agent to invoke and interpret the result.

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%, so the description carries the load. It explains the exit_declaration object well: 'tools' as willow-gate classes, plus self-scored pass_count/fail_count/drift/state_hash, and what the server diff does with it. It also links app_id and session_id to the bound-session prerequisite. Some precise formatting details are missing but the compensation is strong.

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 uses a specific verb and resource: 'Close a bound session and reconcile what you DECLARE you did against what the receipt log shows you actually did.' It clearly identifies the tool's role and differentiates it from siblings like session_bind, session_handoff_write, verify_call, and receipts_tail.

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?

The description gives prerequisite context: a live session bound to app_id is required, and it tells the agent to call session_bind first. It also explicitly says that handoff tools should still be run alongside this one because the tool 'never blocks a handoff.' This is strong usage guidance, though it does not explicitly name an alternative tool for situations where this tool should be skipped.

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/willow-memory/willow-mcp'

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