Skip to main content
Glama

Capture tool use

memory_capture_tool
Idempotent

Post-tool-use hook: append a tool call and result to the pending turn. Substrate memory_* tools are ignored.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "session_id": "<session_id>",
      "tool_use_id": "<tool_use_id>",
      "tool_name": "<tool_name>",
      "tool_input": "<tool_input>",
      "tool_response": "<tool_response>",
      "platform": "<platform>"
    },
    "name": "memory_capture_tool"
  }
}

Input Schema

NameRequiredDescriptionDefault
turn_idNo
platformYes
tool_nameYes
session_idYes
tool_inputYes
tool_use_idYes
agent_contextNo
tool_responseYes
parent_session_idNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnly-but-mutating semantics (readOnlyHint false), idempotent, and non-destructive, so the description only needed to add nuance. It adds that the write appends to an existing turn and excludes sibling memory_* calls, but says nothing about deduplication keys, failure behavior when the turn is missing, or whether ordering is preserved. With annotations covering the safety profile, a 3 fits.

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?

Two short sentences, no filler, with the hook role and the append behavior front-loaded and the exclusion clause immediately after. Every clause carries information an agent needs.

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

Completeness2/5

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

A 9-parameter, 6-required write tool with no parameter documentation anywhere, no output schema, and no explanation of how session_id/turn_id/parent_session_id relate or what the idempotency key is. The description covers the what and the when superficially but leaves an agent unable to construct a correct call from the text alone.

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

Parameters2/5

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

Nine parameters at 0% schema description coverage, and the description names none of them explicitly. Only implicit hints exist ('tool call and result' loosely maps to tool_name/tool_input/tool_response; 'pending turn' gestures at turn_id). Nothing explains session_id vs parent_session_id, the agent_context enum, or the platform field, leaving most of the schema undocumented everywhere.

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: 'append a tool call and result to the pending turn', framed as a post-tool-use hook. It also draws a boundary against siblings by declaring substrate memory_* tools ignored, so an agent can tell it apart from the capture/remember family, though it doesn't name which sibling to use instead.

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 'post-tool-use hook' framing tells the agent the invocation context (fires after a tool call finishes, within an existing turn), and the exclusion of substrate memory_* tools prevents misuse for self-capture. There is no explicit statement about what to do when no pending turn exists, nor a named alternative for other memory writes.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.