Skip to main content
Glama

upload_file

Attach a local file to a file input element by specifying its CSS selector and file path, enabling browser automation to submit forms that require uploads.

Instructions

Attach a local file to an .

Input Schema

NameRequiredDescriptionDefault
pathYes
selectorYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.1/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=false, destructiveHint=false and openWorldHint=true, so the safety profile is covered. The description adds the useful constraint that the target must be a file input, but says nothing about hidden inputs, waiting for the element, multiple-file limits, or what happens on failure.

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. It is efficient, though its brevity is partly under-specification rather than disciplined economy.

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?

An output schema exists so return values need not be explained, but for a two-required-parameter, zero-coverage, open-world browser tool the description supplies no selector format, no path semantics, and no failure behavior — an agent would have to guess on both required inputs.

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% for both required parameters, and the description does not compensate: it never explains that `selector` is a CSS selector locating the file input, nor what form `path` takes (absolute vs relative, host vs container filesystem). The word "local" is the only hint about `path`.

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?

"Attach a local file to an <input type=file>" states a specific verb (attach) and resource (local file / file input), which cleanly separates it from sibling tools like fill_form or type_text. It lacks any explicit naming of those alternatives, so it stops short of full sibling differentiation.

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?

The constraint to file inputs implies when to use it (not for text fields), but there is no explicit when-to-use/when-not guidance, no prerequisites, and no mention of alternatives for uploading via other mechanisms (e.g. drag-and-drop, JS-driven uploads).

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