Skip to main content
Glama
andresolbach

nodriver-mcp-server

Drag and drop

drag

Move an element to a target by simulating mouse press, move, and release. Helps automate sortable lists and sliders that rely on mouse events in undetected Chrome.

Instructions

Drag one element onto another (press, move, release).

Both uids must come from the same take_snapshot. Both ends are scrolled into view and hit-tested first, and the pointer is moved in steps with the button held, which is what mouse-driven sortables and sliders listen for.

This drives the mouse. Native HTML5 drag-and-drop — the dataTransfer kind — is a separate protocol that a synthetic mouse does not trigger in Chrome; if nothing happens on a page that uses it, that is why.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
to_uidYesuid of the element to drop onto, from the most recent take_snapshot.
browserNoWhich browser to act on. Each name is an independent Chrome, created on first use. Omit for the shared default; parallel agents each need their own name.default
from_uidYesuid of the element to pick up, from the most recent take_snapshot.
include_snapshotNoAppend a fresh page snapshot to the response. Worth it when this action changes the page and take_snapshot would be your next call anyway — it saves a round trip, at the cost of a much larger response.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv2.5.0
    • addedInput schema / properties / browser
      Added value: +{
      +  "default": "default",
      +  "description": "Which browser to act on. Each name is an independent Chrome, created on first use. Omit for the shared default; parallel agents each need their own name.",
      +  "type": "string"
      +}
  2. First observedv1.7.2

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=false, but the description goes beyond them by explaining the actual behavioral steps (scrolling into view, hit-testing, stepping pointer movement). It also discloses the significant limitation that synthetic mouse events do not trigger native HTML5 drag-and-drop in Chrome. This adds valuable context beyond the structured annotations without contradiction.

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 lean and well-structured. The core action is stated in the first line, followed by a concise prerequisite sentence and a crucial caveat. Every sentence earns its place—no fluff, and the most important information (action + constraint) is front-loaded.

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?

The description covers all essential context for correct usage: the prerequisite of snapshot UIDs, the hit-testing and scrolling behavior, the stepping pointer movement, and the critical HTML5 drag-and-drop limitation. An output schema exists, so return values need no explanation. There is nothing an agent needs to know to invoke this tool correctly that is missing.

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?

The input schema provides 100% coverage for all four parameters, each with a description. The tool description does not add additional syntactic or semantic detail beyond what the schema already encodes (e.g., the same-snapshot constraint is already in the schema descriptions for from_uid and to_uid). Baseline of 3 is appropriate when the schema carries the parameter documentation burden.

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 begins with a specific verb-resource pair ('Drag one element onto another') and immediately conveys the press-move-release mechanism. It distinguishes itself from sibling tools like click, hover, and scroll by detailing the drag-and-drop nature and the pointer movement behavior, making it clear what makes this tool unique.

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?

The description gives a concrete prerequisite (both uids from the same take_snapshot) and explains the intended use case for mouse-driven sortables and sliders. It also warns against a common failure mode (native HTML5 drag-and-drop) and explains why it won't work. It does not explicitly name alternative tools, but the context is strong enough to guide selection.

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