按键
browser_press_keySimulates pressing a key or key combination such as Enter, Tab, or Ctrl+C on the focused element in a browser tab, optionally with Ctrl, Alt, Shift, or Meta modifiers, enabling keyboard shortcuts and form submission.
Instructions
Press a key on the focused element, optionally with Ctrl/Alt/Shift/Meta modifiers. Supports Enter, Escape, Tab, Backspace, Delete, ArrowUp/Down/Left/Right, PageUp/PageDown, Home/End, F1-F12, a single character, or common combinations such as Ctrl+C and Ctrl+Shift+R.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"key": "<key>"
},
"name": "browser_press_key"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | Yes | Key name or combination, e.g. "Enter", "Escape", "Ctrl+C", "Ctrl+Shift+R" | |
| tabId | No | Tab id (default: active tab) | |
| modifiers | No | Optional modifier keys; equivalent to including them in key with +. |