Skip to main content
Glama

download_file

Download a Moodle file from a pluginfile URL to a local path, creating the target directory if missing.

Instructions

Download a Moodle file (from get_course_contents) to a local path.

The Moodle token is appended automatically. The target directory is created if missing.

Args: file_url: pluginfile.php URL from a module's contents[].fileurl save_path: absolute local path to write the file to

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
file_urlYes
save_pathYes
Behavior3/5

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

With no annotations, the description carries the full burden. It discloses automatic token appending and directory creation, which are important behaviors. However, it does not mention overwrite policy, error handling, or file validation, leaving some uncertainty about edge cases.

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 very concise: three short sentences plus a parameter list. Every sentence adds value, and the structure is clear with no unnecessary words.

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 absence of annotations and output schema, the description covers the key aspects: source, destination, automatic token, and parameter details. It does not discuss return values or errors, but for a download tool, this level is adequate.

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?

The schema coverage is 0% but the description explains both parameters: file_url as a pluginfile.php URL from module contents and save_path as an absolute local path. This adds significant meaning beyond the bare schema names and types.

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 tool downloads a Moodle file to a local path, specifying the source as 'from get_course_contents' which ties to a sibling tool. The verb 'download' and the resource 'Moodle file' are specific and unambiguous.

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 indicates when to use the tool ('from get_course_contents') and provides context about automatic token appending and directory creation. However, it does not explicitly state when not to use it or mention alternative tools, though no direct alternatives exist among siblings.

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/Snaw80/moodle-mcp'

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