Skip to main content
Glama
mnemox-ai

TradeMemory Protocol

by mnemox-ai

verify_audit_chain

Read-onlyIdempotent

Validates the integrity of a trade audit chain by checking that each record's hash links correctly to its predecessor, returning verification details and the first break point if any.

Instructions

Verify the integrity of the audit chain.

Walks the chain from from_seq (default: 1, the genesis record) to to_seq (default: latest), checking that every record's prev_hash matches the previous record's data_hash, and that each data_hash equals SHA256(prev_hash || content_hash).

Returns a dict with verified, checked_count, first_break_at, reason. A first_break_at of None with verified=True means the chain is intact across the verified range.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
to_seqNoEnding sequence_num (inclusive). None = through latest.
from_seqNoStarting sequence_num (inclusive). None = from beginning.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior5/5

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

Beyond the annotations (readOnlyHint, idempotentHint, destructiveHint false), the description adds substantial context: the traversal algorithm, the exact hash relationship, and the meaning of return fields. It even clarifies edge semantics like `first_break_at` being None when verified=True, which is valuable for interpreting results.

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?

The description is well-structured with three concise parts: a one-sentence purpose, a detailed algorithm explanation, and return value semantics. Every sentence adds necessary information with no redundancy or filler.

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 rich schema (100% coverage), strong annotations, and an output schema, the description fully round out the tool's behavior: it explains the verification logic, defaults, and return meaning. Nothing essential is missing for an agent to invoke and interpret results correctly.

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 coverage is 100% for both parameters, so the baseline is 3. The description adds meaning by explaining that `from_seq` defaults to 1 (genesis record) and `to_seq` defaults to latest, complementing the schema's null defaults and making the runtime behavior explicit.

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 clearly states the tool's purpose: 'Verify the integrity of the audit chain.' It details the exact verification process—walking from `from_seq` to `to_seq`, checking `prev_hash` against `data_hash` and verifying the SHA256 computation—which fully distinguishes it from siblings like `verify_audit_hash`.

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 provides clear context on how to use the tool: it specifies the default range (genesis to latest) and how to constrain it via `from_seq`/`to_seq`. It does not explicitly mention alternatives or when not to use it, but the unique behavior makes the intended usage apparent.

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/mnemox-ai/tradememory-protocol'

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