Skip to content

extension_open ​

Open an extension surface or a url, or replay the toolbar action or a shortcut, over the control channel (by hand: --allow-control).

Quick start ​

Open the side panel, then trigger the action button

Asked to open a surface, the agent runs the extension and opens the page in a tab.

Asked to open a surface, the agent runs the extension and opens the page in a tab.

How the agent uses it ​

A url opens in a background tab and answers target.targetId for extension_screenshot and the readers. A replay carries no user gesture.

Page text in the answer ​

Part of this tool's answer is text a web page or the extension wrote. The server fences it between <untrusted-data-ID> and </untrusted-data-ID> with a fresh random ID per call, named in untrusted.boundary. A fence is a signal to the model, not a gate: pair it with --no-ship when the agent reads pages you do not trust. See Server flags and telemetry.

Reference ​

Grouplocal, on by default
TierAct
Needsa dev session, which carries control unless started with allowControl: false
Read onlyno
Destructiveno
Idempotentno
Reaches the open webyes

Inputs ​

InputTypeRequiredDefaultWhat it does
projectPathstringyesProject root of a running session: extension_dev, extension_start, or npx extension dev|start by hand
surface"popup" | "options" | "sidebar" | "devtools" | "newtab" | "history" | "bookmarks" | "action" | "command"noSurface to open; action and command replay; devtools is Chromium only.
namestringnocommand: the chrome.commands name.
panelstringnodevtools: panel title.
waitMsnumbernodevtools: ms to wait (default 15000).
reloadbooleannofalsedevtools: reload the inspected tab.
urlstringnoUrl to open (a path resolves to the extension).
foregroundbooleannofalseRaise the tab; only for a page the person must act on.
newTabbooleannofalseNew tab even if one shows the url.
tabnumbernoWith url: navigate this chrome.tabs id (not a tab position; from dom_snapshot listTabs: true).
asTabbooleannofalseRender the surface in a tab.
browserstringnoSession browser; required when several run.
timeoutnumbernoTimeout ms (default 30000; Firefox 10000; debug port 15000).

When it fails ​

  • The call is refused because no session is live. Start one with extension_dev or extension_start and call again.
  • The control channel is off. The session was started with allowControl: false. Start it again without that flag.
  • The answer depends on the network. This tool reaches the open web, so a refusal can be the network, not the project.

Next ​

  • MCP server: install, the two groups and the session gates
  • Install in your client
  • extension_eval: Evaluate JavaScript in a running extension's background, surface, content script, page or targetId.
  • extension_reload: Reload the extension's background, or a tab, over the control channel (allowControl); a background reload waits up to 5 s.
  • extension_storage: Read or write one chrome.storage key from the background, over the control channel.