Developer
Playwright (Local)
Run browser checks in pinned Chromium on your OrgSDK project runner. Inspect page status and text, capture screenshots and reuse sign-in state.
View 16 plugin functions ↓Use Playwright (Local) in a project
- Check a development preview from a project action
- Interact with page elements and capture a PNG screenshot
- Reuse a named browser session for a signed-in check
Access and credentials
Downloads Playwright's pinned Chromium into project runner storage. Opens websites from the runner, can submit forms and execute JavaScript in the open page, and returns page content, accessibility snapshots and screenshots to OrgSDK. Named sessions store sign-in cookies and browser storage in project runner data for later actions. Headful mode opens Chromium on the runner display.
This plugin does not declare a stored credential requirement.
Install Chromium on the project runner
In Studio, open your project’s Plugins page and enable Playwright (Local). Paste this example into an action in the same project.
// Download the browser once before running a page check.
return await playwrightLocal.installBrowser({});The receipt identifies Chromium and its pinned Playwright version. An installed value of true means this project runner has the browser files.
Workflow examples and guides
Use with OrgSDK
OrgSDK gives external AI clients persistent projects and controlled execution. Plugins add optional tools to those projects. Each run uses pinned plugin versions, and project configuration determines which credentials they can use.
Set up OrgSDK locally ↗Capabilities
16 functions from this published version. Read calls retrieve or process information; write actions can change data in the connected service.
16 of 16 functions
playwrightLocal.browserStatus
Read callCheck whether pinned Chromium is installed for this project runner.
Parameters and return value
| Parameter | Type | Details |
|---|---|---|
headlessOptional | boolean | Defaults to true (Chromium Headless Shell). False selects full Chromium on the runner display. |
Returns Promise<{ browser: string; playwrightVersion: string; installed: boolean }>
playwrightLocal.installBrowser
Write actionDownload this plugin's pinned Chromium into project runner storage. Run once per project runner before browser automation.
Parameters and return value
| Parameter | Type | Details |
|---|---|---|
headlessOptional | boolean | Defaults to true (Chromium Headless Shell). False selects full Chromium on the runner display. |
Returns Promise<{ browser: string; playwrightVersion: string; installed: boolean }>
playwrightLocal.openPage
Write actionOpen an isolated blank page or resume a named session at its saved URL. Close with closePage to checkpoint sign-in state.
Parameters and return value
| Parameter | Type | Details |
|---|---|---|
viewportOptional | { width: number; height: number } | Viewport in CSS pixels. Defaults to 1280 × 720. |
headlessOptional | boolean | Defaults to true (Chromium Headless Shell). False selects full Chromium on the runner display. |
sessionOptional | string | Project-runner session name. Use 1–64 lowercase letters, digits, underscores or hyphens, starting with a letter or digit. |
timeoutMsOptional | number | Playwright operation timeout in ms (1–240000, default 60000). |
idleTimeoutMsOptional | number | Close and save after inactivity between calls, in ms (1000–3600000, default 300000). |
Returns Promise<null>
playwrightLocal.navigate
Write actionNavigate the open page to an HTTP(S) URL.
Parameters and return value
| Parameter | Type | Details |
|---|---|---|
url | string | HTTP(S) URL reachable from the project runner. |
Returns Promise<{ url: string; status: number | null }>
playwrightLocal.click
Write actionClick the element matching a Playwright selector.
Parameters and return value
| Parameter | Type | Details |
|---|---|---|
selector | string | Playwright selector for the target element. |
Returns Promise<null>
playwrightLocal.fill
Write actionReplace the value of an editable field.
Parameters and return value
| Parameter | Type | Details |
|---|---|---|
selector | string | Playwright selector for the target element. |
value | string | Value to enter. |
Returns Promise<null>
playwrightLocal.waitForSelector
Read callWait until the element matching a selector is visible.
Parameters and return value
| Parameter | Type | Details |
|---|---|---|
selector | string | Playwright selector for the target element. |
Returns Promise<null>
playwrightLocal.readText
Read callRead the rendered text of the matching element, up to 1,000 characters.
Parameters and return value
| Parameter | Type | Details |
|---|---|---|
selector | string | Playwright selector for the target element. |
Returns Promise<string>
playwrightLocal.pageInfo
Read callRead the current page title and URL.
Parameters and return value
This call takes no parameters.
Returns Promise<{ url: string; title: string }>
playwrightLocal.press
Write actionPress a key or shortcut on the focused element, or focus the given selector first.
Parameters and return value
| Parameter | Type | Details |
|---|---|---|
key | string | Playwright key or shortcut, such as Enter or Control+a. |
selectorOptional | string | Playwright selector for the target element. |
Returns Promise<null>
playwrightLocal.select
Write actionChoose options in a native select by value. Returns the selected option values.
Parameters and return value
| Parameter | Type | Details |
|---|---|---|
selector | string | Playwright selector for the target element. |
value | string | string[] | An option value, or a list of values for a multiple-select. |
Returns Promise<string[]>
playwrightLocal.snapshot
Read callRead the page accessibility tree as Playwright ARIA snapshot text with element references. Optionally scope it to a selector.
Parameters and return value
| Parameter | Type | Details |
|---|---|---|
selectorOptional | string | Playwright selector for the target element. |
Returns Promise<string>
playwrightLocal.evaluate
Write actionEvaluate JavaScript in the open page. Awaits promises, can modify the page, and returns the JSON result (null for undefined).
Parameters and return value
| Parameter | Type | Details |
|---|---|---|
expression | string | JavaScript expression or zero-argument function, such as document.title. |
Returns Promise<unknown>
playwrightLocal.screenshot
Read callCapture the viewport or full scrollable page as a base64 image. Defaults to a viewport PNG. Use JPEG for larger pages.
Parameters and return value
| Parameter | Type | Details |
|---|---|---|
fullPageOptional | boolean | Capture the full scrollable page when true. |
formatOptional | "png" | "jpeg" | Image format. Defaults to PNG. |
qualityOptional | number | JPEG quality from 0 to 100. |
Returns Promise<string>
playwrightLocal.closePage
Write actionSave a named session and close the page. An unnamed session is discarded.
Parameters and return value
This call takes no parameters.
Returns Promise<null>
playwrightLocal.forgetSession
Write actionDelete saved sign-in state and the resume URL for this named session on the project runner. Close its page first.
Parameters and return value
| Parameter | Type | Details |
|---|---|---|
session | string | Project-runner session name. Use 1–64 lowercase letters, digits, underscores or hyphens, starting with a letter or digit. |
Returns Promise<null>
