Loading...
Loading...
Drive the user's own running browser and ScriptCat from the terminal with the `sctl` CLI: list and organize tabs, windows, bookmarks, history, cookies, downloads and extensions; read and operate pages (accessibility snapshot, click, fill, screenshot, run JavaScript); inspect console errors and network requests; send raw CDP commands or hand a CDP endpoint to Playwright/Puppeteer; and view, search, install, edit, enable, run or delete ScriptCat userscripts and read their logs. Use this skill whenever the user wants something done or looked at in their real browser — "what tabs do I have open", "open this page and click…", "why is this page throwing errors", "which request is failing", "run my Playwright script against my logged-in browser" — or mentions sctl, sctl Browser or ScriptCat, even if they never name the tool. Not for ordinary front-end coding that does not touch the user's browser, and not for developing the sctl repository itself.
npx skill4agent add scriptscat/sctl sctlsctlsctl servesctl <group> <verb>sctl tabs open <url> --backgroundpagedebugcdp send--tab <id>sctl page detach --tab <id>contentTrust: "untrusted-page-content"history rm/clearbrowsing-data clearcookies rm/cleardownloads cancel/erase/delete-filereading-list rmextensions disable--yesCONFIRMATION_REQUIRED--yesbookmarks rmextensions uninstallinstall/edit/enable/disable/deleteAuthorizationsctl status # daemon version, which ScriptCat and sctl Browser instances are connected
sctl scriptcats -o json # paired ScriptCat instances: name, online, product
sctl browsers -o json # paired sctl Browser instances: name, online, productsctl servesctl service startsctl service installsomething is listening at … but does not answer as an sctl daemona daemon is running at …, but its control token cannot be readinvalid control token--data-dirSCTL_DATA_DIRNO_BROWSER_CONNECTEDsctl connectsctl connect--browser <name|ID prefix>SCTL_BROWSERBROWSER_AMBIGUOUS--scriptcat <name|ID prefix>SCTL_SCRIPTCATSCRIPTCAT_AMBIGUOUSsctl get-o jsonsctl browsers -o json # [{"id","name","online","product",…}]
sctl tabs list -o json # {"tabs":[{"tabId","windowId","active","pinned","groupId","title","url"}], …}
sctl tabs open <url> -o json # {"tabId": N}sctl tabs list -o json | jq '.tabs[] | select(.url | contains("localhost:5173"))'error: CODE: message| Exit code | Meaning |
|---|---|
| 0 | Success. Also: |
| 1 | The user rejected the request in the browser |
| 2 | Voided: approval timed out, Ctrl-C, the extension disconnected, or |
| 3 | Everything else: bad arguments, |
| The user wants to… | Use | Details |
|---|---|---|
| List, open, close or organize tabs, windows, tab groups; bookmarks, reading list, history, recently closed, downloads, cookies, browsing data, extensions | | references/browser-data.md |
| Read a page, click, fill, select, press keys, upload, wait, navigate, screenshot, run JavaScript, handle a dialog | | references/page.md |
| See console errors, uncaught exceptions, network requests and their headers and bodies | | references/page.md |
| Do something no command covers, with one raw CDP command | | references/cdp.md |
| Run a Playwright or Puppeteer script against the user's browser, logins included | | references/cdp.md |
| List, read, search, install, edit, enable, disable or delete ScriptCat userscripts; run a background script once; read a script's logs | | references/scriptcat.md |
pagepagedebugcdp sendTAB=$(sctl tabs open https://example.com --background -o json | jq .tabId) # prints {"tabId": N}
sctl page wait --load load --tab $TAB # tabs open returns before the page has loaded
sctl page snapshot --tab $TAB # accessibility tree; actionable nodes carry [ref=eN]
sctl page fill e12 "hello" --tab $TAB # act on a ref from that snapshot
sctl page click e15 --tab $TAB
sctl page wait --text "Saved" --tab $TAB # confirm the effect instead of assuming it
sctl page snapshot --tab $TAB # the page changed: take a new snapshot for new refs
sctl page detach --tab $TABSTALE_REFsctl page eval 'document.body.innerText' --tab $TABPAYLOAD_TOO_LARGE--root <ref|css>-f <path>sctl debug start --tab $TAB| Error code | What to do |
|---|---|
| The browser is not paired or not running: ask the user to open it or pair with |
| Look up the name with |
| Look up the name with |
| Take a new |
| |
| The message names the last unmet condition (obscured, hidden, disabled…): fix that, or raise |
| A JS dialog is open: `sctl page dialog accept |
| The debugger could not attach, often because the browser put the tab to sleep or a dialog was left behind: |
| A background tab produced no screenshot: retry with |
| |
| A network error such as a refused connection. HTTP 404/500 are not failures; the status is reported |
| The user cancelled the infobar, the tab closed or the browser disconnected: retry if it still makes sense |
| A Playwright/Puppeteer client holds this browser: disconnect it or run |
| A destructive command without |
| Over 4 MiB: narrow the request ( |
| The page threw; the message carries the exception |
sctl <command> --help