Skip to main content
Glama

Get File Info

get_file_info
Read-only

Retrieve detailed file metadata including size, timestamps, permissions, and type to understand file characteristics without accessing content. Works within allowed directories.

Instructions

Retrieve detailed metadata about a file or directory. Returns comprehensive information including size, creation time, last modified time, permissions, and type. This tool is perfect for understanding file characteristics without reading the actual content. Only works within allowed directories.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
contentYes
Behavior3/5

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

Annotations already declare readOnlyHint=true, so the agent knows this is safe. The description adds useful context about the scope ('only works within allowed directories') and what information is returned, but doesn't detail error conditions, rate limits, or authentication needs beyond the directory restriction.

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 sentences with zero waste: first states purpose, second details return values, third adds crucial constraint. Each sentence earns its place by providing distinct, necessary information in a front-loaded manner.

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 moderate complexity (single parameter, read-only), annotations cover safety, and an output schema exists, the description is mostly complete. It explains the tool's purpose, return values, and a key constraint, though it could mention error handling or prerequisites more explicitly.

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 0%, but the description doesn't explain the 'path' parameter beyond what's implied by context. With only one parameter and an output schema present, the baseline is 3, as the description adds minimal value over the schema but doesn't compensate for the coverage gap.

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 verb ('retrieve') and resource ('detailed metadata about a file or directory'), distinguishing it from siblings like read_file (which reads content) or list_directory (which lists items). It specifies this is for metadata only, not content access.

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 with 'perfect for understanding file characteristics without reading the actual content' and 'only works within allowed directories,' giving implicit guidance on when to use it. However, it doesn't explicitly name alternatives like list_directory_with_sizes or compare to other metadata tools.

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/agentward-ai/agentward'

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