Skip to main content
Glama

Upload Media

upload_media

Upload a file to a Drupal media library by providing its path; optionally set title, alt text, name, and media type.

Instructions

Upload a file to the media library.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
altNo
nameNo
titleNo
file_pathYes
media_typeNoimage

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.7/5.0
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 behavioral burden, and it discloses almost nothing. It does not mention allowed file types, size limits, permission requirements, duplicate-name handling, or whether a new media entity is created. For a write/mutation tool with zero annotation coverage this is a substantial gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single front-loaded sentence with no filler, which is structurally clean. The brevity here reflects under-specification rather than wasteful padding, so it is not penalized heavily, but there is little substance to earn more.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 5-parameter mutation tool with no annotations and 0% schema documentation, the description is far too thin. The existence of an output schema excuses explaining return values, but nothing covers behavior, constraints, or the undocumented parameters.

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

Parameters2/5

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

Schema description coverage is 0% across 5 parameters, so the description must compensate and it does not. Only file_path is loosely implied by 'upload a file'; alt, name, title, and media_type receive no explanation at all, including the meaning of the 'image' default for media_type.

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 states a specific verb and resource ('Upload a file to the media library'), which is more informative than a tautology. However, it does nothing to distinguish itself from closely related siblings such as create_media, media_create_from_url, and media_create_from_base64, so the agent must infer the boundary itself.

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?

There is no guidance on when to use this tool versus the many media-creating alternatives (create_media, media_create_from_url, media_create_from_base64, media_bulk_import). No prerequisites, no exclusions, no conditions given.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools