Skip to main content
Glama
Savvy-Tech-Sphere

usable-browser-agent-free

browser_upload_file

Upload local files to a web page by targeting a file input, upload button, or dropzone. Provide absolute file paths; it sets the input's files directly or simulates drag-and-drop when needed.

Instructions

Attach local file(s) to the page WITHOUT opening the OS file picker (the picker cannot be automated — never click elements that open it). Pass the ref of a file input (hidden ones appear in snapshots as 'file-input ... [hidden]'), or of an upload button/dropzone near it, plus absolute local file paths. Sets the input's files directly, or simulates a drag-and-drop when no file input is found.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
refYesRef of the file input, upload button, or dropzone.
modeNoauto (default): find and fill the file input. drop: force a drag-and-drop onto the ref'd element (for dropzones).
pathsYesAbsolute paths of local files to attach.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.7.0

TDQS

A4.5/5.0
Behavior4/5

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

With no annotations provided, the description carries the full burden. It discloses that the tool sets the input's files directly or simulates drag-and-drop when no file input is found, and explains the hidden input detection in snapshots. It doesn't mention potential side effects like change events or failure modes, but for a browser automation tool it covers the key behaviors well.

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?

The description is slightly long but every sentence adds value: the warning is front-loaded, then the ref explanation, then the modes. It is well-structured and not redundant. Could be tightened slightly, but the density of useful information justifies its length.

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?

For a specialized browser automation tool, the description covers the essentials: how to locate the input, what to pass, and the two modes. It even includes a warning about the picker. No output schema exists, so return values are not expected. It is fairly complete for an agent to call it correctly.

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 coverage is 100%, so parameters are documented in the schema. The description adds value beyond that: it explains that 'ref' can be a file input, upload button, or dropzone, and that hidden inputs appear in snapshots. It also clarifies the 'drop' mode for dropzones. This goes beyond the schema's simple descriptions.

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's purpose: attaching local files to a page without using the OS picker. It uses a specific verb 'Attach', identifies the resource 'local file(s) to the page', and includes a critical warning about not clicking elements that open the picker. This clearly distinguishes it from sibling tools like browser_click or browser_type.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides explicit guidance: when to use it (to upload files), how to find the ref (including hidden inputs appearing in snapshots), and the two modes (auto vs drop). It also warns against clicking elements that open the picker, which is essential for correct usage. No alternatives are named, but the tool's specialization is clear from the context.

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