Skip to main content
Glama
Document Reader MCP Server

Document Reader MCP Server

by abdo544445

list_directory

Lists supported document files (.pdf, .docx, .xlsx, .xls, .pptx, .ppt, .csv) in a specified directory so you can discover which files are available to read.

Instructions

List all supported document files (.pdf, .docx, .xlsx, .xls, .pptx, .ppt, .csv) in a directory. Useful for discovering which files are available to read.

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": {
      "directoryPath": "<directoryPath>"
    },
    "name": "list_directory"
  }
}

Input Schema

NameRequiredDescriptionDefault
directoryPathYesAbsolute path to the directory

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

B3.2/5.0
Behavior2/5

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

With no annotations supplied, the description carries the full behavioral burden and leaves key traits unstated: whether subdirectories are traversed recursively, what happens on a nonexistent or unreadable path, whether hidden files are included, and whether returns are bare names or full paths. These omissions materially affect how an agent calls and interprets the tool.

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?

Two short sentences, with the operation and supported file types front-loaded before the usage note. The extension list is genuinely informative rather than filler; the second sentence is slightly soft but not wasted.

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

Completeness3/5

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

This is a simple one-parameter tool with no output schema, so the burden is modest, but the definition never clarifies the return shape or recursion scope, which are the two facts an agent needs to decide whether this alone answers its question.

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?

Only one parameter exists and the schema documents it fully ('Absolute path to the directory'), so the schema already does the work. The description adds no extra constraint such as path format quirks or trailing-slash behavior, so 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 (list) and resource (document files in a directory) and enumerates the supported extensions, which makes it distinguishable from read/document/search siblings simply by name. It stops short of explicitly positioning itself against those siblings, but the operation is unambiguous.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The clause 'Useful for discovering which files are available to read' implies the use case (inventory before reading), but it is framed as a soft benefit rather than instruction: no 'call this first, then use read_document' sequencing and no exclusion for when to skip it.

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