Prerequisites
Set your API token and base URL, then install the packages for your language below. Other thanenable_chromedriver, the example uses default start options, including your account’s default proxy pool. Proxy, fingerprint, and other options are in the API reference.
Run an example
The examples use a one-time profile. To reuse a saved login, pass a persistent profile UUID to the session call, keepingenable_chromedriver on.
- Python
- JavaScript
Requires Python 3.12 or newer. Selenium’s Python API is synchronous, so use the synchronous Surfsky client:Save as Run it:
surfsky_selenium.py:Click, type, and scroll
Prefer human emulation over Selenium’sclick, send_keys, and action chains. Human.* commands move the cursor and type with human timing, and they go through ChromeDriver. Replace the selector with an input on your page:
Connection settings
Use/chromedriver/{internal_uuid} as command_executor, not the CDP ws_url. The URL grants access to the browser, so keep it private. Do not pass local launch arguments for proxy or fingerprint; those are set in the start request. chromedriver_not_enabled means the browser was started without the flag.
Stop the session
driver.quit() ends the WebDriver session but leaves the browser running, because ChromeDriver attached to a browser it did not launch. The SDK stops it when the session scope exits, including on errors.
Without the SDK, stop the browser through the API: