Value and clipboard tools
Set element values and read or write the clipboard.
Set element values and read or write the clipboard.
| Tool | Description | Platforms |
|---|---|---|
set_value | Set an element's value by element_token. | macOS, Linux, Windows |
clipboard_read | List available system clipboard types and optionally return privacy-sensitive plain text. | macOS, Linux, Windows |
clipboard_write | Replace the system clipboard with exactly one value: plain text, an image from an absolute local path, or a file URL from an absolute local path. | macOS, Linux, Windows |
Served by cua-driver mcp; see MCP tools for every tool.
set_value#Effect: destructive, idempotent. Platforms: macOS, Linux, Windows.
Set an element's value by element_token. A popup button / select dropdown: selects the menu item whose title or value matches value (case-insensitive). Safari <select> is set through the DOM; AppKit and Chromium popups list items only while open, so the menu is opened, the item pressed and the menu closed again (in the background the user's front window keeps key focus). An unknown value lists the options. Any other element: writes AXValue (sliders, steppers, date pickers, native text fields).
A Finder file name cell (list or icon view, not being edited) is renamed through Finder's scripting interface with Finder left in the background, and the new name is read back from disk; the value is the full new name with its extension. macOS asks the user once to allow Cua Driver to control Finder. Finder's Get Info Name field is refused with file_name_needs_rename. For free-form text in web inputs use type_text_chars: WebKit ignores AXValue writes.
macOS parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
session | string | For multi-call work, prefer a short public session label and repeat it on every call that accepts it. | |
value | string | required | New value, coerced to the element's type. |
window_id | integer | Window ID. Omit with element_token. |
Parameters on every platform
| Parameter | Type | Default | Description |
|---|---|---|---|
element_token | string | Element handle <snapshot_id>:<row> from get_window_state: row [11] of a read whose snapshot_id is s0000002a is "s0000002a:11" (also in structuredContent.elements[].element_token). Returns an explicit stale error naming the current snapshots once a newer read supersedes it. | |
pid | integer | Target process ID. Optional with element_token (the token carries the pid). |
Example arguments
{"value":"<value>"}clipboard_read#List available system clipboard types and optionally return privacy-sensitive plain text. Clipboard content is never retained in telemetry.
Effect: read-only. Platforms: macOS, Linux, Windows.
| Parameter | Type | Default | Description |
|---|---|---|---|
include_text | boolean | false | Return plain-text clipboard content in addition to the available types. Clipboard content is privacy-sensitive and is never retained in telemetry. |
session | string | For multi-call work, prefer a short public session label and repeat it on every call that accepts it. Omit it to use the authenticated transport's implicit lifecycle session. |
clipboard_write#Replace the system clipboard with exactly one value: plain text, an image from an absolute local path, or a file URL from an absolute local path. Returns the available types for read-back before paste.
Effect: destructive, idempotent. Platforms: macOS, Linux, Windows.
| Parameter | Type | Default | Description |
|---|---|---|---|
file_path | string | Absolute path to a local file to place on the clipboard as a file URL. | |
image_path | string | Absolute path to a local image to place on the clipboard. | |
session | string | For multi-call work, prefer a short public session label and repeat it on every call that accepts it. Omit it to use the authenticated transport's implicit lifecycle session. | |
text | string | Plain text to place on the clipboard. |