Skip to main content
Glama

save_file

Download any file type from a URL and save it locally. Returns the absolute path of the saved file for persisting crawl artifacts.

Instructions

Download a resource from a URL and save it to the local output directory. Handles any file type (images, PDFs, CSVs, etc.) via HTTP GET. Returns the absolute path of the saved file. Use to persist crawl artifacts; path traversal is blocked for security.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlYesFully qualified URL of the resource to download (e.g. "https://example.com/report.pdf"). Must include protocol.
subdirNoSubdirectory within the output directory to save into (e.g. "images", "data/csv"). Created automatically if it doesn't exist.
headersNoOptional HTTP request headers to send with the download (e.g. Referer, Origin, User-Agent). Use for CDNs that reject requests lacking a Referer.
filenameNoCustom filename to save as (e.g. "report.pdf"). If omitted, derived from the URL's last path segment. Path traversal characters (../) are rejected.
output_dirNoOverride the default output directory. Can be relative (resolved against CWD) or absolute. If omitted, uses the configured output_dir from settings.
Behavior3/5

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

With no annotations, description carries full burden. It mentions HTTP GET, any file type, returns absolute path, and path traversal blocking. However, lacks details on error handling, size limits, or overwrite behavior.

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 front-loaded with purpose, then general capability, then use case. No superfluous content.

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?

No output schema, but return value is simple. Parameters well-documented. Missing error/edge-case info, but overall adequate for a file download tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, but description adds value: notes path traversal blocked for filename, subdir auto-created. Provides usage hints beyond schema.

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?

Clearly states 'Download a resource from a URL and save it to the local output directory.' This gives specific verb and resource, distinguishing it from all browser-interaction sibling tools.

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?

Explicitly says 'Use to persist crawl artifacts' and mentions security constraint. Provides clear context but does not explicitly state when not to use or alternative 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/Mingye-Lu/AgenticCrawler'

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