ProtectedfeaturesThe capability flags for the backend this driver instance serves. Populated from the
RemoteBrowserProviderContext at BaseRemoteBrowserProvider.Connect time (call
this.applyContext(ctx) first). Drives BaseRemoteBrowserProvider.RequireFeature.
ProtectedproviderThe backend's display name for this driver instance, used in capability-error messages. Populated from the RemoteBrowserProviderContext; falls back to the driver class name.
The backend's supported-feature flags for this driver instance.
Read-only accessor over the internally-held BaseRemoteBrowserProvider.features. The engine consults this (and the underlying provider metadata) to decide which capability-gated session methods are safe to call; a driver consults it via BaseRemoteBrowserProvider.RequireFeature.
ProtectedAcquireObtains a CDP endpoint for Hyperbrowser by creating a service session via the seam, and returns it alongside a HyperbrowserSessionBackend for the live-view / native-AI / release concerns. Captures the capability context first so the inherited capability gating uses the backend's flags.
The provider context (features, configuration, control mode, context user).
A promise resolving to the acquired CDP endpoint + Hyperbrowser backend hooks.
ProtectedapplyCaptures the connection context onto the instance so BaseRemoteBrowserProvider.Features, BaseRemoteBrowserProvider.RequireFeature, and capability-error messages have the backend's flags and name. A concrete BaseRemoteBrowserProvider.Connect should call this first.
The provider context handed to Connect.
ProtectedbuildBuilds the BrowserConfig used to attach the shared adapter to the acquired CDP endpoint.
Always attaches via CDP (ConnectType: 'cdp') — a raw CDP websocket would otherwise be
misclassified as a Playwright server by scheme auto-detection. Viewport hints come from the
context configuration when supplied.
The CDP endpoint to attach to.
The provider context, whose Configuration may carry viewport hints.
The browser config for PlaywrightBrowserAdapter.Launch.
Opens a session: captures the context, has the driver acquire a CDP endpoint, attaches a shared PlaywrightBrowserAdapter to it over CDP, and returns the shared CdpRemoteBrowserSession. The adapter + backend are retained for Disconnect.
The host services and connection parameters for this session.
A promise resolving to the live remote-browser session handle.
ProtectedcreateCreates the PlaywrightBrowserAdapter the session will drive. A dedicated factory seam so tests can substitute a fake adapter without a real browser, and so a specialized driver could supply a pre-configured adapter if ever needed. Production drivers use the default.
A fresh, un-launched PlaywrightBrowserAdapter.
Releases the driver's own backend resources for the live session: closes the attached adapter and releases the backend. Both steps are best-effort and independent so teardown always completes; the retained references are cleared regardless of outcome. Idempotent — safe to call when nothing is connected.
A promise that resolves once teardown has run.
ProtectednotBuilds the standard RemoteBrowserCapabilityNotSupportedError for an un-overridden capability or a failed feature requirement, stamped with this driver's backend name.
The feature / method name to report.
The error to throw or reject with.
ProtectedRequireDefense-in-depth guard: asserts a SupportedFeatures flag is enabled before the driver performs
a capability-gated action, throwing RemoteBrowserCapabilityNotSupportedError if it is
false/omitted. A driver should call this at the top of any capability-gated work so that even a
direct (engine-bypassing) caller cannot run an action the metadata says is off.
The IRemoteBrowserProviderFeatures flag to require.
StaticSetBinds the HyperbrowserClientFactory every HyperbrowserRemoteBrowser instance uses
to construct its client at acquire time. Production binds the real @hyperbrowser/sdk adapter here
once at startup; tests inject a FakeHyperbrowserClient.
The factory that builds the IHyperbrowserClient for a session.
Remote Browser driver for Hyperbrowser.
Construct via the engine's
ClassFactorypath (default constructor); it builds the Hyperbrowser client from the clientFactory at AcquireSession time. The factory is a static seam — production binds the real@hyperbrowser/sdkadapter once via HyperbrowserRemoteBrowser.SetClientFactory; tests inject aFakeHyperbrowserClient. Everything past acquiring the CDP endpoint (action mapping, capability gating, screencast, teardown) is inherited from BaseCdpRemoteBrowserProvider.Registered via
@RegisterClass(BaseRemoteBrowserProvider, 'HyperbrowserRemoteBrowser').