Skip to main content
Glama

get_document_info

Extract document metadata including page count, sheet count, slide count, and file size from Excel, Word, PDF, and text files to analyze document structure and properties.

Instructions

Get document metadata (page count, sheet count, slide count, file size, etc.)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
file_pathYesAbsolute path to the document file
file_typeNoOverride file type detection (optional). Specify format explicitly instead of relying on extension

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
errorNo
pagesNo
sheetsNo
slidesNo
tablesNo
headersNo
successNo
encodingNo
metadataNo
file_sizeNo
file_typeNo
key_countNo
item_countNo
line_countNo
paragraphsNo
total_colsNo
total_rowsNo
total_wordsNo
Behavior2/5

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

No annotations are provided, so the description carries the full burden. It states 'Get document metadata' which implies a read-only operation, but doesn't disclose behavioral traits like error handling (e.g., if file doesn't exist), performance considerations, or authentication needs. The description is minimal and lacks context beyond the basic action.

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 a single, efficient sentence with zero waste. It's front-loaded with the core purpose and includes helpful examples (page count, etc.) that add value without verbosity.

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?

Given the tool's low complexity (simple metadata retrieval), 100% schema coverage, and the presence of an output schema (which handles return values), the description is reasonably complete. It clearly states what the tool does, though it lacks usage guidelines and behavioral details that could enhance agent understanding.

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 the schema already documents both parameters thoroughly. The description adds no parameter-specific information beyond implying metadata retrieval, which is covered by the tool's purpose. Baseline 3 is appropriate as the schema does the heavy lifting.

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?

The description clearly states the verb 'Get' and the resource 'document metadata' with specific examples (page count, sheet count, slide count, file size, etc.). It distinguishes from sibling tools like 'read_document' (which likely reads content) and 'write_document' (which modifies content), though it doesn't explicitly mention these distinctions.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., file existence), when not to use it, or how it differs from siblings like 'read_document' beyond the metadata focus implied in the purpose.

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/mcpc-tech/docsmith-mcp'

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