Skip to main content

Python SDK for webmate

Project description

webmate Python SDK

This directory contains a webmate Python SDK. WebmateSession aggregates service clients for browser sessions, the job engine, device control, test management, mail testing, artifacts, images, Selenium services, blob storage, and package management.

Quick start

from webmate_sdk import AuthInfo, WebmateEnvironment, WebmateSession

session = WebmateSession(
    auth=AuthInfo(api_token="<token>", email="user@example.com"),
    environment=WebmateEnvironment(),
    project_id=None,  # set to ProjectId(...) if you work in a fixed project
)

# Query Selenium capabilities in the default project:
capabilities = session.selenium.get_capabilities()

# Trigger a job run:
from webmate_sdk.jobs import JobConfigName, PortName, WMValue, WMDataType

inputs = {
    PortName("vehicleSpec"): WMValue(WMDataType("LiveExpeditionSpec"), {"foo": "bar"}),
}
run_id = session.job_engine.start_job(
    JobConfigName("MyJob"),
    job_instance_name="Nightly",
    input_values=inputs,
)

Most client methods accept either the strongly typed identifier wrappers from webmate_sdk.ids or plain strings/UUIDs.

Note: Certain responses are returned as plain dictionaries instead of bespoke value objects. Extend or adapt the models to match your use cases.

Requirements

  • Python 3.9+
  • requests>=2.31 (installed automatically with the package)

Install

Install the SDK in editable mode:

pip install webmate-sdk

SDK tests

Run the SDK unit tests:

pytest tests -v

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

webmate_sdk-0.1.0.tar.gz (19.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

webmate_sdk-0.1.0-py3-none-any.whl (31.2 kB view details)

Uploaded Python 3

File details

Details for the file webmate_sdk-0.1.0.tar.gz.

File metadata

  • Download URL: webmate_sdk-0.1.0.tar.gz
  • Upload date:
  • Size: 19.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.3

File hashes

Hashes for webmate_sdk-0.1.0.tar.gz
Algorithm Hash digest
SHA256 20262e9c2c5e96e879ea97502571445152c89a8afad4bfee47f0c756c84f61f4
MD5 a334e581a620540ece36fd5e90d26375
BLAKE2b-256 a7ce037e92d79b074cb5bfd36a477cecbb3f73f4e92de83dd7533805b757cc3c

See more details on using hashes here.

File details

Details for the file webmate_sdk-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: webmate_sdk-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 31.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.3

File hashes

Hashes for webmate_sdk-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 627774eda1a9d1d8b0e1a7eca46eb22422e3df5aba6d78de6efa59c1592a2e40
MD5 063197a59afd01e46a02866772d2e8f1
BLAKE2b-256 af495bfab48dd120726cf4a6e171ad64c248efa4dfbcfd573641fbaec0af9856

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page