Skip to main content
These methods wrap common multi-step patterns into single API calls. Under the hood, they create and run specialized workflows.
Python uses snake_case (e.g., login, download_files); TypeScript uses camelCase (e.g., login, downloadFiles). Parameter tables show Python names. TypeScript names are the camelCase equivalents.
Automate logging into a website using stored credentials. This creates a login workflow, executes it, and optionally waits for completion.
from skyvern.schemas.run_blocks import CredentialType

result = await client.login(
    credential_type=CredentialType.skyvern,
    credential_id="cred_abc123",
    url="https://app.example.com/login",
    wait_for_completion=True,
)
print(result.status)

Parameters

ParameterTypeRequiredDefaultDescription
credential_typeCredentialTypeYes-How credentials are stored. Options: skyvern, bitwarden, onepassword ("1password" in TS), azure_vault.
urlstrNoNoneThe login page URL.
credential_idstrNoNoneThe Skyvern credential ID (when using skyvern type).
promptstrNoNoneAdditional instructions for the AI during login.
browser_session_idstrNoNoneRun login inside an existing browser session.
browser_addressstrNoNoneConnect to a browser at this CDP address.
proxy_locationProxyLocationNoNoneRoute browser traffic through a geographic proxy.
webhook_urlstrNoNoneURL to receive a POST when the login finishes.
totp_identifierstrNoNoneIdentifier for TOTP verification.
totp_urlstrNoNoneURL to receive TOTP codes.
wait_for_completion (Python) / waitForCompletion (TS)boolNoFalseBlock until the login finishes.
timeoutfloatNo1800Max wait time in seconds.
extra_http_headersdict[str, str]NoNoneAdditional HTTP headers.
max_screenshot_scrolling_timesintNoNoneNumber of screenshot scrolls.
browser_profile_idstrNoNoneLoad a browser profile into the session.
request_optionsRequestOptionsNoNonePer-request configuration (see below).
Bitwarden-specific parameters:
ParameterTypeDescription
bitwarden_collection_idstrBitwarden collection ID.
bitwarden_item_idstrBitwarden item ID.
1Password-specific parameters:
ParameterTypeDescription
onepassword_vault_idstr1Password vault ID.
onepassword_item_idstr1Password item ID.
Azure Key Vault-specific parameters:
ParameterTypeDescription
azure_vault_namestrAzure Key Vault name.
azure_vault_username_keystrSecret name for the username.
azure_vault_password_keystrSecret name for the password.
azure_vault_totp_secret_keystrSecret name for the TOTP secret.

Returns WorkflowRunResponse

Example: Login then extract data

from skyvern.schemas.run_blocks import CredentialType

session = await client.create_browser_session()

# Login
await client.login(
    credential_type=CredentialType.skyvern,
    credential_id="cred_abc123",
    url="https://app.example.com/login",
    browser_session_id=session.browser_session_id,
    wait_for_completion=True,
)

# Now extract data from the authenticated session
result = await client.run_task(
    prompt="Go to the billing page and extract all invoices",
    browser_session_id=session.browser_session_id,
    wait_for_completion=True,
)
print(result.output)

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.