chrome_evaluate
Execute JavaScript in an active Chrome tab, optionally targeting by URL or title, and retrieve JSON-serializable results for page inspection or automation.
Instructions
Evaluate JavaScript in an existing Chrome tab. Runs in the page context and returns JSON-serializable values.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| targetId | No | Chrome tab id to target. | |
| background | No | If true, avoid explicit Chrome focus/tab activation (default). Pass false to allow foreground work. | |
| expression | Yes | ||
| urlIncludes | No | Match the target tab by URL substring. | |
| awaitPromise | No | Await a returned promise (default true). | |
| titleIncludes | No | Match the target tab by title substring. |