Skip to main content
Glama

Fetch Document

fetch-document
Read-only

Retrieve documents from web URLs or local file paths and convert them into MCP content blocks as resource links or embedded resources.

Instructions

Fetch documents from URLs or local file paths. Downloads remote URLs into MEDIA_GEN_DIRS and returns MCP content blocks as resource_link (default) or embedded resource.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sourcesYesArray of document sources: HTTP(S) URLs or file paths (absolute or relative to the first MEDIA_GEN_DIRS entry). Max 20 documents.
tool_resultNoControls content[] shape: 'resource_link' (default) emits ResourceLink items, 'resource' emits EmbeddedResource blocks with base64 blob.resource_link
fileNoBase path for output files (used when downloading from URLs). If multiple documents are downloaded, an index suffix is added.
Behavior1/5

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

The description states 'Downloads remote URLs into MEDIA_GEN_DIRS', indicating a write operation, but annotations set readOnlyHint=true. This contradiction severely undermines transparency and could mislead an agent.

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?

Two concise sentences: the first states the core purpose, the second adds key details. No fluff, front-loaded, and every word earns its place.

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?

The description covers the main behavior, output types, and download destination. However, missing details like supported document formats, error handling, and a description of MEDIA_GEN_DIRS, along with the contradiction, prevent full completeness. Still adequate for a simple tool.

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 coverage is 100%, so the schema already describes all parameters. The description adds context about output formats (resource_link vs embedded resource) but does not explain the 'file' parameter further. It meets the baseline but adds limited value.

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 it fetches documents from URLs or local file paths, differentiating it from sibling tools like fetch-images and fetch-videos. However, it does not explicitly name these alternatives, slightly reducing clarity.

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?

No explicit when-to-use or when-not-to-use guidance is provided. The purpose is implied by the tool name and sibling context, but an agent might not know if this tool supports all document types or if there are prerequisites.

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/strato-space/media-gen-mcp'

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