Actions
Pass an actions array on any scrape, extraction, crawl, or search request to drive the page before content is captured. Useful for logins, filters, pagination, and infinite-scroll sites.
Supported actions
click— click an element by CSS selectortype— fill an input with textpress— press a keyboard key (e.g. "Enter")scroll— scroll by pixels in either directionwait— wait for a selector or a fixed timeoutscreenshot— capture a screenshot at this stepexecute_js— run inline JavaScript in the pageextract— re-extract after actions complete
Example
actions-example.ts
await stack0.extraction.extractAndWait({url: "https://example.com/search",mode: "markdown",actions: [{ type: "type", selector: "input[name=q]", text: "playwright" },{ type: "press", key: "Enter" },{ type: "wait", selector: ".results", timeout: 5000 },{ type: "scroll", direction: "down", pixels: 1200 },{ type: "screenshot" },],});
Proxy & Stealth
Every scrape accepts stealth: true (default) and proxy: "residential" | "datacenter". Stealth runs the page through playwright-extra's evasion patches; proxy uses your configured provider via the WEBDATA_PROXY_SERVER environment variable.