Skip to main content

ringwire

A typed Python client for the Ring Partner API (the api.amazonvision.com API behind the Ring Appstore), including the parts most samples skip: sensors, the two-step media downloads, chime playback, webhook verification, and the account-linking nonce.

Built for Watermark and published on its own so other Ring Appstore developers do not have to re-read the docs I already read.

pip install ringwire

What it covers

Area Calls
Auth RingClient.exchange_code, RingClient.refresh (form-encoded, as Ring requires)
Users and linking me(), confirm_account_link(nonce), update_integration(status="completed")
Devices list_devices(), status(), capabilities(), configurations(), location()
Sensors status() exposes flood_faulted, freeze_faulted, contact_faulted, tamper_detected, temperature, humidity; reported_at is None for the 1970 "never reported" epoch
History event_history(), iter_event_history() (follows links.next, stops on the empty page)
Media download_image() and download_clip() do the 303 two-step and read X-Media-Timestamp / X-Media-Origin
Live create_whep_session(), close_whep_session(), rtsps_url()
Chimes play_chime(device_id, audio_ref), with slots read from configurations()
Webhooks verify_signature, verify_and_parse, parse_event, make_event, every documented event type including the Early Access sensor events
Nonce compute_nonce, match_nonce (URL-safe base64, no padding, 600 s window, constant-time)

Things the docs say that this library enforces

  • The image and clip endpoints never trigger a capture. A 416 raises MediaNotFound so the caller can start a live session first.
  • Sensor events have no history endpoint. Persist them on receipt.
  • Webhook signatures are computed over the raw body bytes. Pass the bytes, not the parsed JSON.
  • Refresh tokens are not Bearer tokens.

Example

from ringwire import RingClient, verify_and_parse

client = RingClient(access_token)
sensors = [d for d in client.list_devices() if client.status(d.id).flood_faulted is not None]

# In your webhook handler (raw bytes, before any JSON parsing):
event = verify_and_parse(raw_body, headers["X-Signature"], signing_key)
if event.type == "flood_detected":
    ...

Tests

pip install -e ".[dev]" && pytest

MIT. Not affiliated with Ring or Amazon.

Metadata

Release files for ringwire 0.1.0

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

Source distribution (sdist)

Source distribution for ringwire 0.1.0
File Size Uploaded Provenance
ringwire-0.1.0.tar.gz 19.3 kB Without provenance Details

Built distribution (wheel)

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

Total release size: 35.5 kB

Release files / ringwire-0.1.0.tar.gz

Download URL ringwire-0.1.0.tar.gz
Size 19.3 kB
Tags Source
SHA-256 checksum
How to use checksums
af1dac8d67b6c8c4bb7b15d38dd87e6ccf38bbe489978ce81e089fd450b5985d
BLAKE2b-256 checksum
How to use checksums
458b6a45be4246b9aeb878e87d8e1508ef151a5a67f10a145a1954de1917bceb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.4

Release files / ringwire-0.1.0-py3-none-any.whl

Download URL ringwire-0.1.0-py3-none-any.whl
Size 16.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
dc4558d9a79e911f521aab6f149b8fe5b855bc4d633a8b2da12f9081ca0a52fd
BLAKE2b-256 checksum
How to use checksums
2a1a57d9a4c139ae446545049d1ca585c99ceed4eb630695ab7fc8f9fed92e6e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.4

Security for ringwire 0.1.0

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.

Release history Release notifications | RSS feed

This release

0.1.0 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