Wait for condition
browser_wait_forWait for specified text to appear, disappear, or a CSS selector to become visible, ensuring UI tests sync after async updates.
Instructions
Waits for text to appear, text to disappear, or a selector to become visible. Use after actions that trigger async updates.
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>"
},
"name": "browser_wait_for"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | No | Wait until this text is visible. | |
| selector | No | Wait until this CSS selector is visible. | |
| textGone | No | Wait until this text is gone. | |
| sessionId | Yes | Session id returned by browser_start. | |
| timeoutMs | No |