Skip to main content
A browser session is a persistent browser instance that stays alive between API calls. Use sessions to chain multiple tasks in the same browser without losing cookies, local storage, or login state. For conceptual background, see Browser Sessions.
Python uses snake_case (e.g., create_browser_session); TypeScript uses camelCase (e.g., createBrowserSession). Parameter tables show Python names. TypeScript names are the camelCase equivalents.
Spin up a new cloud browser session.

Parameters

generate_browser_profile is not yet accepted as a keyword by the SDK methods (watch the changelog for SDK availability). Until SDK support lands, pass it from Python via request_options with additional_body_parameters={"generate_browser_profile": True} (see Request options below); from TypeScript, call the REST API directly. You can also toggle it on a live session via PATCH /v1/browser_sessions/{browser_session_id} — the value is read when the session ends. See Save a session’s profile.

Returns BrowserSessionResponse

Example: Chain multiple tasks in one session


Request options

Override timeout, retries, or headers for this call by passing request_options (Python) or a second options argument (TypeScript).