Member Junction
    Preparing search index...

    Hierarchy (View Summary)

    Index

    Constructors

    Accessors

    Methods

    • Capture one frame on demand and push it through the active screencast's callback.

      Lets callers force an immediate live-view refresh (e.g. the first paint, or right after a navigation settles) on adapters whose screencast only emits frames on a viewport repaint.

      Default implementation is a no-op resolve — safe to call when no screencast is running or the adapter has no screencast support. Adapters with a live screencast (e.g. PlaywrightBrowserAdapter) override this to emit a real frame.

      Returns Promise<void>

    • Read the page's CURRENT text selection (window.getSelection().toString()).

      Used by the remote-browser human "copy-out" path — the viewer reads what the human selected on the remote page and writes it to the local clipboard. Default implementation returns an empty string so adapters without a live page don't break — it's a non-throwing, additive default. Adapters backed by a real page (e.g. Playwright) override this to return the live selection.

      Returns Promise<string>

      The selected text, or '' when nothing is selected / unavailable.

    • Capture the current page's title for cheap perception / sync.

      Default implementation returns an empty string so adapters without a live page don't break — it's a non-throwing, additive default. Adapters backed by a real page (e.g. Playwright) override this to return the page title.

      Returns Promise<string>

      The page title, or '' when unavailable.

    • Read the visible text of the current page for agent perception.

      Returns the rendered (visible) text content of the page body — useful for an LLM controller that needs the page's textual state without a screenshot. Adapters backed by a live page (e.g. Playwright) override this to return the real page text.

      Default implementation returns an empty string so adapters that cannot read page text don't break — it's a non-throwing, additive default.

      Returns Promise<string>

      The page's visible text, or '' if unavailable.

    • Introspect a single element matched by a CSS selector — its existence, visibility, text, and bounding box — without ever throwing on a miss.

      Default implementation reports the element as absent so adapters that cannot query the DOM don't break — additive and non-throwing. Adapters backed by a real page (e.g. Playwright) override this.

      Parameters

      • _selector: string

      Returns Promise<ElementInfo>

      An ElementInfo; { Exists:false, Visible:false, Text:'' } when missing.

    • Reset per-session state for the given origin while preserving auth tokens. Called between tests in shared-context mode so that the next test starts with a clean app state but doesn't have to re-login.

      Cleans (for the given origin):

      • sessionStorage (entirely)
      • localStorage EXCEPT entries matching auth-token patterns
      • All IndexedDB databases (clears cached entity metadata)
      • Service worker registrations

      Preserves: cookies (handled at context level by Playwright — they survive naturally), auth-token localStorage entries (Auth0, MSAL, generic OAuth).

      Best-effort: never throws.

      Parameters

      • origin: string

      Returns Promise<void>

    • Set extra HTTP headers for all requests to a specific domain. Used by AuthHandler for Bearer, APIKey, and Basic auth.

      Headers are additive — calling this multiple times for the same domain merges headers. Calling with a different domain adds a new set of domain-scoped headers.

      Implementation note: Playwright uses page.route() interception; other adapters may use their own request interception mechanism.

      Parameters

      • domain: string
      • headers: Record<string, string>

      Returns Promise<void>

    • Start capturing the audio playing inside the browser tab, invoking onChunk for each encoded AudioCaptureChunk until StopAudioCapture is called.

      Default implementation is a no-op resolve: it starts no capture and emits no chunks. This is the safer additive default — a consumer that opportunistically requests tab audio on an adapter that can't provide one simply receives nothing rather than an exception. Adapters that can tap the page's media elements (e.g. PlaywrightBrowserAdapter) override this to emit real chunks.

      Parameters

      • _onChunk: (chunk: AudioCaptureChunk) => void

        Callback invoked with each captured audio chunk.

      Returns Promise<void>

    • Wait until the page reaches a given load state.

      Useful after a navigation/action to let the page settle before the next perception step. Default implementation is a no-op resolve so adapters that cannot observe load state don't break — additive and non-throwing. Adapters backed by a real page (e.g. Playwright) override this.

      Parameters

      • _state: "load" | "domcontentloaded" | "networkidle"

      Returns Promise<void>