SDK Reference
OpenSteer SDK Lifecycle Reference
Reference OpenSteer lifecycle APIs for creation, launch, attachment, namespace utilities, and cleanup in browser automation apps.
Quick Answer
Lifecycle APIs control how OpenSteer instances start, attach, expose runtime state, and cleanly shut down browser resources.
Local Chrome Helpers
Opensteer.listLocalProfiles()Opensteer.fromSystemChrome(...)
Lifecycle
launch(options?: LaunchOptions): Promise<void>
Launch a new browser (local or cloud). In local mode, starts a Playwright Chromium instance. In cloud mode, creates a session and connects via CDP.
await opensteer.launch({ headless: true })
static from(page: Page, config?: OpensteerConfig): Opensteer
Wrap an existing Playwright Page without launching a new browser. The caller
retains ownership of the browser lifecycle. Not supported in cloud mode.
const opensteer = Opensteer.from(page, { name: 'my-scraper' })
close(): Promise<void>
Close the browser and release all resources. In cloud mode, also closes the cloud session and action WebSocket.
Utility
getNamespace(): string
Return the resolved storage namespace.
getConfig(): OpensteerConfig
Return the resolved configuration object.
getStorage(): LocalSelectorStorage
Return the local selector storage instance.
clearCache(): void
Clear all persisted selectors for this namespace and reset the snapshot cache.
Covered Features
sdk:clearCachesdk:closesdk:fromsdk:fromSystemChromesdk:getConfigsdk:getNamespacesdk:getStoragesdk:launchsdk:listLocalProfiles
