Skip to main content
Glama

Find Related Documents

find_related_documents
Read-onlyIdempotent

Find documents that might be related to an entity based on amount, vendor, date, and reference matching. Shows both already-linked documents and AI-suggested matches. Use when user asks "are there any receipts for this transaction?" or "find documents related to this invoice".

Input Schema

NameRequiredDescriptionDefault
companyNoWhich company to read, by name or id, when the account has more than one (see list_companies). Leave it out to use the only company, or the default.
entity_idYesEntity ID to find related documents for
entity_typeYesEntity type: transaction, invoice, bill, estimate, contact, project, expense_claim

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive, closed-world behavior, so the safety profile is covered. The description adds genuinely new behavioral context: results are a mix of confirmed links and AI-suggested (i.e., unverified) matches, which tells the agent to treat part of the output as probabilistic. No info on result limits or confidence scoring, but the key caveat is present.

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?

Three tight sentences: what it does, what it returns, when to use it. The result-shape caveat is placed before the trigger examples, so nothing is buried and no sentence is filler.

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?

With no output schema and full annotation and parameter coverage, the description still explains the two result categories an agent must interpret. What's missing is minor: no note on result caps, ranking, or whether suggested matches include a confidence score.

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 description coverage is 100%, so all three parameters including the entity_type value list are documented in structured data. The description mentions amount/vendor/date/reference matching but those are internal heuristics, not inputs, so it adds nothing beyond the schema. Baseline 3 applies.

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 ('Find documents') plus the matching basis (amount, vendor, date, reference) and the result shape (already-linked vs AI-suggested). This implicitly separates it from a plain search_documents or get_document_links, but it never names those siblings to make the routing explicit.

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?

Provides two concrete user-utterance triggers ('are there any receipts for this transaction?', 'find documents related to this invoice'), which gives an agent a clear situational hook. It stops short of saying when NOT to use it or which sibling (search_documents, get_document_links) is the alternative.

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.