tb_pressKey
Sends a key or key chord, such as Enter, Tab or Control+A, to the focused element in an active TestingBot browser session to simulate real keyboard input during tests.
Instructions
Press a key (or chord) on the active browser session. Uses W3C key names: 'Enter', 'Tab', 'Escape', 'Control+A', 'Meta+Shift+Z', etc. Sent to the currently-focused element.
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": {
"sessionId": "<sessionId>",
"key": "<key>"
},
"name": "tb_pressKey"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | Yes | Key name or chord | |
| sessionId | Yes | Session ID from tb_openBrowser |