Skip to main content
Glama

upload_image

Upload a captured screenshot to file inputs or drag-and-drop targets on a webpage, using an element reference for hidden fields or coordinates for visible areas.

Instructions

Upload a previously captured screenshot to a file input or drag & drop target. Supports two approaches: (1) ref -- for targeting specific elements, especially hidden file inputs, (2) coordinate -- for drag & drop to visible locations like Google Docs. Provide either ref or coordinate, not both.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
refNoElement reference ID from read_page or find tools (e.g., "ref_1", "ref_2"). Use this for file inputs (especially hidden ones). Provide either ref or coordinate, not both.
tabIdYesTab ID where the target element is located. This is where the image will be uploaded to.
imageIdYesID of a previously captured screenshot (from the computer tool's screenshot action), e.g. "img_..." as reported in the screenshot result.
filenameNoOptional filename for the uploaded file (default: "image.png").
coordinateNoViewport coordinates [x, y] for drag & drop to a visible location like Google Docs. Provide either ref or coordinate, not both.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
provenanceNo
interactionReceiptNo
Behavior4/5

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

With no annotations, the description carries the full burden. It discloses the two behavioral modes, the prerequisite of a previously captured screenshot, and the mutually exclusive ref/coordinate constraint. It stops short of detailing side effects or failure behavior, but covers the essential traits for safe invocation.

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 three sentences that front-load the core purpose, then succinctly explain the two approaches and the exclusivity constraint. Every sentence earns its place, with no filler or redundant restatement of the tool name.

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

Completeness5/5

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

Given the tool's moderate complexity, a 100% schema-covered parameter set, and the presence of an output schema, the description is complete enough: it specifies prerequisites, target types, usage modes, and a key constraint. The agent has sufficient context to select and invoke the tool correctly.

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 the baseline is 3. The description reinforces the ref/coordinate distinction and the 'not both' rule, but does not add new semantic information beyond what the schema already provides for each parameter.

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 uses a specific verb ('Upload') and resource ('previously captured screenshot to a file input or drag & drop target'), clearly distinguishing it from sibling upload tools. It also outlines two concrete approaches, making the tool's scope unmistakable.

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?

Provides clear guidance on when to use 'ref' (hidden file inputs) versus 'coordinate' (drag & drop to visible locations like Google Docs), and explicitly warns not to provide both. However, it does not name alternative sibling tools or explicitly state when not to use this tool.

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/sylin-org/ghostlight'

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