spa_assert
Run assertions on page elements to verify existence, visibility, text content, or count using CSS selectors.
Instructions
Run assertions on page elements.
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": {
"type": "<type>",
"selector": "<selector>"
},
"name": "spa_assert"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | URL to navigate to first (optional) | |
| type | Yes | Assertion type | |
| value | No | Expected value (for text and count assertions) | |
| session | No | Session ID | default |
| contains | No | For text assertion: check if text contains value instead of exact match | |
| selector | Yes | CSS selector to check |