Install
pip install skyvern is the lightweight SDK for Skyvern Cloud and remote API calls. Embedded local SDK features such as Skyvern.local() and local browser control require pip install "skyvern[local]". Local server and local stdio MCP commands require pip install "skyvern[server]". Guided quickstart and migrations currently require Docker Compose or a source checkout.Initialize the client
Create aSkyvern instance with your API key. All methods are async.
Constructor parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
api_key / apiKey | str / string | - | Required. Your Skyvern API key. Get one at app.skyvern.com/settings. |
environment | SkyvernEnvironment | CLOUD / Cloud | Target environment. See Environments. |
base_url / baseUrl | str / string | None | Override the API base URL for self-hosted deployments. |
timeout / timeoutInSeconds | float / number | None / 60 | HTTP request timeout in seconds. |
max_retries / maxRetries | int / number | None / 2 | Number of times to retry failed requests. |
headers | dict / Record<string, string> | None | Additional headers included with every request. |
Python-only constructor options
Python-only constructor options
| Parameter | Type | Default | Description |
|---|---|---|---|
follow_redirects | bool | True | Whether to follow HTTP redirects. |
httpx_client | httpx.AsyncClient | None | Provide your own httpx client for custom TLS, proxying, or connection pooling. |
Environments
Three built-in environment URLs:| Environment | URL | When to use |
|---|---|---|
CLOUD / Cloud | https://api.skyvern.com | Skyvern Cloud (default) |
STAGING / Staging | https://api-staging.skyvern.com | Staging environment |
LOCAL / Local | http://localhost:8000 | Local server started with skyvern run server |
Local mode
Run Skyvern entirely on your machine - no cloud, no network calls.Skyvern.local() reads your .env file, boots the engine in-process, and connects the client to it.
Prerequisite: Install the local extra with pip install "skyvern[local]". For local browser control, also run python -m playwright install chromium.
skyvern quickstart, a Chromium window opens so you can watch the AI work.
| Parameter | Type | Default | Description |
|---|---|---|---|
llm_config | LLMConfig | LLMRouterConfig | None | None | Override the LLM. If omitted, uses LLM_KEY from .env. |
settings | dict | None | None | Override .env settings at runtime. Example: {"MAX_STEPS_PER_RUN": 100} |
Waiting for completion
By default, task and agent runs return immediately after queuing. You get a run ID and need to poll for results yourself. Passwait_for_completion to have the SDK poll automatically until the run reaches a terminal state (completed, failed, terminated, timed_out, or canceled):
| Parameter | Type | Default | Description |
|---|---|---|---|
wait_for_completion / waitForCompletion | bool / boolean | false | Poll until the run finishes. |
timeout | float / number | 1800 | Maximum wait time in seconds. |
Request options
Every method accepts per-request overrides for timeout, retries, and headers:| Option | Type | Description |
|---|---|---|
timeout_in_seconds / timeoutInSeconds | int / number | HTTP timeout for this request. |
max_retries / maxRetries | int / number | Retry count for this request. |
additional_headers / headers | dict / Record<string, string> | Extra headers for this request. |
additional_query_parameters | dict | Extra query parameters (Python only). |
additional_body_parameters | dict | Extra body parameters (Python only). |
abortSignal | AbortSignal | Signal to abort the request (TypeScript only). |
apiKey | string | Override the API key for this request (TypeScript only). |
Next steps
Browser Automation
Control browsers with Playwright + AI
Tasks
Run browser automations with
run_taskWorkflows
Create and run multi-step automations
Error Handling
Handle errors and configure retries

