Skip to main content
Glama

upload_files

Destructive

Set local files on any file input using a CSS selector and absolute paths, bypassing JavaScript's read-only restriction.

Instructions

Set files on a file input, which JS cannot do (input.files is read-only). Give a CSS selector for the and absolute local paths. Runs as a single CDP batch so the DOM node ids stay valid across the sequence.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathsYes
timeoutNo
selectorYes
session_idNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already mark this as destructive and non-read-only. The description adds a valuable behavioral detail: the operation runs as a single CDP batch to keep DOM node IDs valid, which is beyond what annotations convey. No contradiction is present.

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?

Two sentences with no filler. The purpose is front-loaded, and the behavioral note is concise. Every clause earns its place.

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?

An output schema exists to cover return values, and annotations cover safety. The description addresses purpose, input specification, and a key atomicity behavior. It is nearly complete for a tool of this complexity, though it omits details on optional parameters and potential side effects like change events.

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?

With 0% schema description coverage, the description must explain parameters. It clarifies 'selector' as a CSS selector and 'paths' as absolute local paths, but it does not mention 'timeout' or 'session_id'. Since the two required parameters are adequately described, it partially compensates for the schema gap.

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 states a specific verb and resource ('Set files on a file input') and explains the underlying limitation ('input.files is read-only'), which distinguishes this tool from any sibling. It is immediately clear what the tool does and why it exists.

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?

It instructs the agent to provide a CSS selector for the file input and absolute local paths, which clarifies how to invoke it. It implies the use case (setting files on an input) but does not explicitly contrast with alternatives; however, no sibling tool handles file inputs, so the guidance is sufficient.

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