Skip to main content

Helixwright

Helixwright is the Python automation SDK for Helix Browser.

Version 0.2.3 is a breaking V5-only architecture. It does not use CDP, WebDriver, Playwright, Selenium, direct chrome.exe launch, local profile folders, or local fingerprint generation.

Runtime Model

Client talks to Helix Browser Desktop Local API. Local API creates or reuses a server-owned profile, starts an automation session, and returns the private Browser RPC endpoint.

Page is returned by hw.launch(). Page actions use Browser RPC V5 only:

  • /rpc is used only for rpc.hello discovery.
  • Runtime page control must switch to /rpc/v5.
  • Required V5 methods are input.action, input.pointer_path, element.resolve, element.action, and frames.list.
  • Older RPC V1/V2/V3/V4 cores are rejected.

Install

pip install helixwright

Local source development:

cd "G:\Helix Browser\repos\helixwright"
pip install -e .
python tests\ci.py

Quick Start

import helixwright as hw

with hw.launch("https://example.com", name="demo") as page:
    page.wait_for("body")
    print(page.title())
    page.locator("body").click()

Pass only the metadata you actually need. In the common case, URL and optional proxy are enough; profile identity and fingerprint are owned by Helix.

with hw.launch(
    "https://example.com",
    proxy="http://user:pass@127.0.0.1:7890",
) as page:
    print(page.profile_id, page.session_id)

Reuse an existing Helix profile explicitly:

with hw.launch("https://example.com", reuse_profile_id="p_existing") as page:
    print(page.url)

Public Objects

  • Client: Local API client and managers.
  • Page: primary page/session object returned by launch().
  • Locator: selector-bound element action object.
  • Input: low-level trusted mouse/keyboard/path injection.
  • MotionProfile: Python-visible motion policy for browser-core trajectories.
  • TraceController: AI/debug trace support, available as page.trace.

The retired pre-V5 public element model, manual fingerprint object, account lookup launch, and old RPC fallback model are not part of this API.

Launch API

hw.launch(
    url=None,
    *,
    reuse_profile_id=None,
    name=None,
    group=None,
    tags=None,
    start_pages=None,
    proxy=None,
    client=None,
    base_url=None,
    headless=False,
    timeout_ms=30000,
    humanize=None,
    motion=None,
)

Reusable config:

cfg = hw.LaunchConfig(
    name="shop",
    url="https://example.com",
    proxy="http://127.0.0.1:7890",
    motion=hw.MotionProfile.balanced(),
)

with hw.launch(config=cfg) as page:
    page.locator("body").wait()

Unsupported old arguments raise TypeError, including account_id, profile_id, fingerprint, chrome, user_data_dir, persona, seed, and extra_args.

Locator Actions

Default actions are trusted browser-core actions. Eligible root-page locators use the V5 frame-flat element path, so clicks can auto-scroll the correct root, iframe/OOPIF, or scroll container target before clicking.

Frame-flat locator selectors supported by the current core:

  • Plain CSS.
  • Interactive text=... / text:"..." selectors.
  • role=button@@name:... and other role+name selectors.
  • placeholder=..., aria-label=..., aria=..., title=..., alt=....
  • testid=..., matching data-testid, data-test, data-qa, and data-cy.
  • Simple positive Drission text filters when they compile to one CSS scope plus one text filter.
email = page.locator("input[type=email]")
email.fill("user@example.com")

page.locator("button[type=submit]").click()
page.locator("#result").wait("visible")
print(page.locator("#result").text())

Nested locators:

page.locator("form").locator("button[type=submit]").click()

Diagnostics:

print(page.locator("#login").resolve())
print(page.locator("#login").explain())
print(page.targets())  # browser tab/WebContents inventory
print(page.frames())   # document frame/OOPIF inventory

targets() is not a frame list. Use frames() when diagnosing iframe or OOPIF visibility. Locator.exists(), Locator.count(), and page.probe prefer V5 frame-flat evidence for eligible selectors, so they should agree with the trusted Locator.click() path on the same core.

Low-Level Input

Use page.input only when you intentionally need raw control. For normal automation, prefer Locator.click() and Locator.fill().

page.input.click(100, 200)
page.input.wheel(600)
page.input.key("Enter")

page.input.pointer_path([
    {"x": 10, "y": 20, "dt": 0, "kind": "move"},
    {"x": 12, "y": 22, "dt": 16, "kind": "down", "buttons": 1},
    {"x": 40, "y": 55, "dt": 80, "kind": "up", "buttons": 0},
])

pointer_path() is one atomic Browser RPC V5 call. It does not emulate a path with many SDK round trips.

Humanize And Trajectory

humanize controls action-to-action timing. MotionProfile controls compact Python-visible motion policy. Browser core generates default trusted pointer paths from that policy.

with hw.launch("https://example.com", humanize="default") as page:
    page.locator("#email").fill("user@example.com")
    page.locator("#submit").click()

Implemented timing behavior:

  • humanize=True and humanize="default" enable deterministic per-profile think-time.
  • humanize="careful" uses a slower, more deliberate timing profile.
  • Timing is seeded from server-returned profile behavior data, so different profiles get different pacing distributions.
  • Session nonce adds small run-to-run variation without using per-call random jitter.

Motion behavior:

  • Locator.click() uses Browser RPC V5 element.action; the browser core owns the trusted click path, frame/OOPIF coordinates, auto-scroll, and receipt.
  • hw.MotionProfile exposes presets such as fast, balanced, careful, and slider.
  • hw.launch(..., motion=...) sets the default motion profile for Locator, page.input, and Page.scroll().
  • page.input.drag() uses the page motion profile when profile/duration/hold/ overshoot/tremor are not explicitly provided.
  • page.input.pointer_path(points) is the public low-level way to inject a full custom trajectory as one atomic core RPC.
motion = hw.MotionProfile.slider(seed=123)

with hw.launch("https://example.com", motion=motion, humanize="careful") as page:
    page.input.drag(120, 350, 380, 350)
    page.input.pointer_path([
        {"x": 120, "y": 350, "dt": 0, "kind": "down", "buttons": 1},
        {"x": 190, "y": 351, "dt": 90, "kind": "drag", "buttons": 1},
        {"x": 300, "y": 349, "dt": 130, "kind": "drag", "buttons": 1},
        {"x": 380, "y": 350, "dt": 90, "kind": "up", "buttons": 0},
    ])

MotionProfile is intentionally the Python-side policy object, not a trajectory generator. Browser RPC V5 owns default element actions, frame/OOPIF routing, trusted event dispatch, and default path generation.

Trace

Trace is a debug and AI authoring surface, separate from normal runtime actions. Use TraceRecorder for new work; it writes an append-only evidence directory with canonical events.jsonl, actions.jsonl, probes.jsonl, channels/*.jsonl, content-hashed assets, screenshots, and a report.

with hw.launch("https://example.com") as page:
    with page.trace.start_session("trace-example", mode="authoring") as trace:
        page.locator("body").wait()
        page.probe.interactables()
        page.probe.locator("button[type=submit]").candidates()
        page.locator("button[type=submit]").click()
        page.probe.state({"loaded": lambda p: "example.com" in p.url})
    trace.report()

For deep failure analysis, opt in to heavier evidence:

with page.trace.start_session("trace-debug", mode="failure_debug", network_bodies=True) as trace:
    page.probe.cookies()
    page.probe.storage()
    page.probe.listener_hints("button[type=submit]")

CLI capture for an already-running automation session:

python -m helixwright trace --session auto_123 --duration 15 --output trace-example
python -m helixwright trace --session auto_123 --mode failure_debug --network-bodies --output trace-debug

Client Managers

client = hw.Client()
print(client.health())
print(client.session())

profile = client.profiles.create(name="demo", proxy="http://127.0.0.1:7890")
profile.update(name="renamed")
profile.clone(count=2)
profile.sync_up()
profile.sync_down()

client.proxy.check("http://127.0.0.1:7890")
client.cores.list()
client.cores.ensure("chromium", "149.0.7827.156")
client.browser.active()
client.browser.start(profile.id)
client.browser.stop(profile.id)
client.browser.stop_all()
client.automation.list()
client.automation.stop("auto_123")

The SDK no longer exposes client.fingerprint or client.automation.start(). Use hw.launch() / client.automation.launch() so profile creation and session start remain one server-owned operation.

Errors

Common error types:

Error Meaning
LocalApiUnavailable Desktop Local API is unreachable.
DesktopNotLoggedIn Desktop is reachable but not logged in.
LocalApiError Local API returned a business error.
ProfileNotFound The requested profile id does not exist.
AutomationEndpointUnavailable Local API/core did not return a usable V5 RPC endpoint.
AutomationSessionNotFound The requested automation session does not exist.
RpcError Browser RPC returned a structured error.
TransportError Browser RPC transport failed, usually because the browser exited.
WaitTimeoutError A page wait condition timed out.

Examples

cd "G:\Helix Browser\repos\helixwright"
python examples\99_offline_mock_demo.py
python examples\00_helixwright_quickstart.py
python examples\01_client_managers.py
python examples\02_launch_config_and_actions.py
python examples\03_native_trace_state_machine.py

Metadata

Release files for helixwright 0.2.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for helixwright 0.2.3
File Size Uploaded Provenance Actions
helixwright-0.2.3.tar.gz 156.4 kB Without provenance Details for helixwright-0.2.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for helixwright 0.2.3
File Interpreter ABI Platform Actions
helixwright-0.2.3-py3-none-any.whl Python 3 none any Details for helixwright-0.2.3-py3-none-any.whl

Total release size: 305.0 kB

Release files / helixwright-0.2.3.tar.gz

Download URL helixwright-0.2.3.tar.gz
Size 156.4 kB
Tags Source
SHA-256 checksum
How to use checksums
04d860a87d020949b19d8cf75403648ee846c6ba6d5c55f64de78001352e970e
BLAKE2b-256 checksum
How to use checksums
a90d0e82b91b258c5ef988a8330a2154bb45db5e771bb1bb4fc96250752bddf7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.10.0

Release files / helixwright-0.2.3-py3-none-any.whl

Download URL helixwright-0.2.3-py3-none-any.whl
Size 148.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
757b88edabedf964790758226925a9c440eb6611c1dd64a93d69015186d5bef7
BLAKE2b-256 checksum
How to use checksums
53100588f0d2138bb4f612ed927812134866e0798b905a0ee3a4c83485b357d2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.10.0

Security for helixwright 0.2.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.2.3 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page