ui_evaluate
Runs custom JavaScript expressions inside the TradingView page context to access unexposed DOM properties or perform low-level browser automation.
Instructions
Evaluate arbitrary JavaScript expression directly in the TradingView page context. WHEN TO USE: Call for specialized low-level browser automation or retrieving unexposed DOM properties. SIDE EFFECTS: STATE_MUTATING (Arbitrary JavaScript execution in page context). LIMITATIONS: Advanced tool; expressions run within page sandbox.
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": {
"expression": "<expression>"
},
"name": "ui_evaluate"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| expression | Yes | JavaScript expression to evaluate in the page context. Wrap in IIFE for complex logic. |