Skip to main content
Glama
ochen1
by ochen1

upload_file

Upload files to web pages by selecting elements and specifying local file paths. This tool interacts with file input fields to transfer files from your system to web applications during testing or automation workflows.

Instructions

Upload a file through a provided element.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
uidYesThe uid of the file input element or an element that will open file chooser on the page from the page content snapshot
filePathYesThe local path of the file to upload
includeSnapshotNoWhether to include a snapshot in the response. Default is false.
Behavior3/5

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

Annotations indicate readOnlyHint=false, confirming this is a write operation, which aligns with 'Upload' implying mutation. The description adds minimal behavioral context beyond this—it doesn't specify error conditions, file size limits, supported formats, or what happens if the element isn't found. With annotations covering the safety profile, a baseline 3 is appropriate, but more operational details would be helpful.

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 a single, focused sentence with zero wasted words. It front-loads the core action ('Upload a file') and efficiently specifies the mechanism. Every word earns its place, making it easy for an agent to parse quickly.

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

Completeness3/5

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

Given no output schema and annotations only covering read/write status, the description is minimally complete. It identifies the tool's function but lacks details on return values, error handling, or integration with sibling tools. For a mutation tool in a browser automation context, more guidance on expected outcomes and failure modes would improve completeness.

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

Parameters3/5

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

Schema description coverage is 100%, so parameters are well-documented in the schema itself. The description adds no additional semantic context about parameters beyond implying a file input element via 'provided element.' It doesn't clarify the relationship between 'uid' and the element or explain 'includeSnapshot' usage. Baseline 3 is correct given high schema coverage.

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 clearly states the action ('Upload a file') and specifies the mechanism ('through a provided element'), which distinguishes it from generic file upload tools. However, it doesn't explicitly differentiate from sibling tools like 'take_screenshot' or 'take_snapshot' that also involve file operations, leaving some ambiguity about when to choose this specific upload method.

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?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., needing an open page with a file input element), exclusions, or compare it to sibling tools like 'fill_form' that might handle file uploads differently. The agent must infer usage from the parameter descriptions alone.

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/ochen1/chrome-devtools-mcp-mux'

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