Skip to main content
A browser profile is a snapshot of browser state: cookies, local storage, session data. Create a profile from a completed run, then load it into future workflow runs to skip login and setup steps. For conceptual background, see Browser Profiles.
Python uses snake_case (e.g., create_browser_profile); TypeScript uses camelCase (e.g., createBrowserProfile). Parameter tables show Python names. TypeScript names are the camelCase equivalents.
Create a profile from a completed workflow run.
profile = await client.create_browser_profile(
    name="production-login",
    workflow_run_id="wr_abc123",
)
print(profile.browser_profile_id)  # bpf_abc123

Parameters

ParameterTypeRequiredDescription
namestrYesDisplay name for the profile.
descriptionstrNoOptional description.
workflow_run_idstrConditionalThe workflow run ID to snapshot. The run must have used persist_browser_session=True. Required if browser_session_id is not provided.
browser_session_idstrConditionalThe browser session ID to snapshot. Required if workflow_run_id is not provided.
request_optionsRequestOptionsNoPer-request configuration (see below).
You must provide either workflow_run_id or browser_session_id.

Returns BrowserProfile

FieldTypeDescription
browser_profile_idstrUnique ID. Starts with bpf_.
namestrProfile name.
descriptionstr | NoneProfile description.
created_atdatetimeWhen the profile was created.

Example: Create a profile from a login workflow

# Step 1: Run a workflow with persist_browser_session
run = await client.run_workflow(
    workflow_id="wpid_login_flow",
    parameters={"username": "demo@example.com"},
    wait_for_completion=True,
)

# Step 2: Create a profile from the run
profile = await client.create_browser_profile(
    name="demo-account-login",
    workflow_run_id=run.run_id,
)

# Step 3: Use the profile in future runs (skip login)
result = await client.run_workflow(
    workflow_id="wpid_extract_invoices",
    browser_profile_id=profile.browser_profile_id,
    wait_for_completion=True,
)
Session archiving is asynchronous. If create_browser_profile fails immediately after a workflow completes, wait a few seconds and retry.

Request options

Override timeout, retries, or headers for this call by passing request_options (Python) or a second options argument (TypeScript).
from skyvern.client.core import RequestOptions

request_options=RequestOptions(
    timeout_in_seconds=120,
    max_retries=3,
    additional_headers={"x-custom-header": "value"},
)
Option (Python)Option (TypeScript)TypeDescription
timeout_in_secondstimeoutInSecondsint / numberHTTP timeout in seconds.
max_retriesmaxRetriesint / numberRetry count.
additional_headersheadersdict / Record<string, string>Extra headers.
additional_query_parameters-dictExtra query parameters.
additional_body_parameters-dictExtra body parameters.
-abortSignalAbortSignalSignal to cancel the request.
-apiKeystringOverride API key.