Skip to main content

webpush-rs

Fast Web Push (VAPID + AES128GCM) for Python — the Rust web-push crate behind a PyO3 binding.

The VAPID JWT signing and payload encryption run in native Rust; Python sees a single blocking send_one. Compared to a pure-Python sender it roughly halves per-send CPU and adds no Python dependency footprint (the crypto is statically linked, not pulled in as cryptography/http-ece).

End-to-end latency is dominated by the network round-trip to the push service (FCM/Apple), so this is not "faster delivery" — it's lower CPU and memory on the sending host, which matters when fanning out to many subscribers.

Install

pip install webpush-rs        # or: uv pip install webpush-rs

Prebuilt wheels are published for CPython 3.8+ (abi3, one wheel per platform) on Linux (manylinux x86_64 + aarch64), macOS, and Windows.

Usage

import asyncio
import webpush_rs

# send_one is blocking (it drives a small internal Tokio runtime); call it off
# the event loop from async code.
status = await asyncio.to_thread(
    webpush_rs.send_one,
    endpoint,        # subscription.endpoint
    p256dh,          # subscription.keys.p256dh
    auth,            # subscription.keys.auth
    vapid_private,   # url-safe base64 VAPID private key
    "mailto:you@example.com",  # VAPID subject (mailto: or https URL)
    payload_bytes,   # the notification payload
)
# 201 = delivered; 404/410 = endpoint gone (delete the subscription); 0 = error (raises).

License

MIT OR Apache-2.0.

Download files

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

Source Distribution

webpush_rs-0.1.4.tar.gz (23.3 kB view details)

Uploaded Source

Built Distributions

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

webpush_rs-0.1.4-cp38-abi3-win_amd64.whl (2.7 MB view details)

Uploaded CPython 3.8+Windows x86-64

webpush_rs-0.1.4-cp38-abi3-manylinux_2_28_x86_64.whl (3.2 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.28+ x86-64

webpush_rs-0.1.4-cp38-abi3-manylinux_2_28_aarch64.whl (3.4 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.28+ ARM64

webpush_rs-0.1.4-cp38-abi3-macosx_11_0_arm64.whl (2.6 MB view details)

Uploaded CPython 3.8+macOS 11.0+ ARM64

webpush_rs-0.1.4-cp38-abi3-macosx_10_12_x86_64.whl (2.3 MB view details)

Uploaded CPython 3.8+macOS 10.12+ x86-64

File details

Details for the file webpush_rs-0.1.4.tar.gz.

File metadata

  • Download URL: webpush_rs-0.1.4.tar.gz
  • Upload date:
  • Size: 23.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for webpush_rs-0.1.4.tar.gz
Algorithm Hash digest
SHA256 6e475b1e4bb5803fff205d16b54a4d60a56779fef74485991ffdebb826547777
MD5 8c41b0528aec509da3541c0d1a8521b9
BLAKE2b-256 1e653ff9628fd939684744626858e555bb00b06c070f1d638fa750100ad07cdf

See more details on using hashes here.

Provenance

The following attestation bundles were made for webpush_rs-0.1.4.tar.gz:

Publisher: release.yml on coseto6125/webpush-rs

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file webpush_rs-0.1.4-cp38-abi3-win_amd64.whl.

File metadata

  • Download URL: webpush_rs-0.1.4-cp38-abi3-win_amd64.whl
  • Upload date:
  • Size: 2.7 MB
  • Tags: CPython 3.8+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for webpush_rs-0.1.4-cp38-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 d6ac3c6a4678c76e34da672195fb5e65b15a237d54e20e231404128b3e96f754
MD5 dab42d561a71eafba7d8fac7c34868d9
BLAKE2b-256 764d3b9f05bbb3de741c48b3dddf703623e81ccd10ecbef637ba45d845de22ff

See more details on using hashes here.

Provenance

The following attestation bundles were made for webpush_rs-0.1.4-cp38-abi3-win_amd64.whl:

Publisher: release.yml on coseto6125/webpush-rs

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file webpush_rs-0.1.4-cp38-abi3-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for webpush_rs-0.1.4-cp38-abi3-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 2e8d07f28f954a009925657b7cbe3a02329bddf6fb05423191c40a751b87d399
MD5 6b8e19e41ea1740419c8b29648c119c5
BLAKE2b-256 0ef3b2a3bf57ad014c2a3ac667665aa6922cb2d6b64e0321922be87737b823b3

See more details on using hashes here.

Provenance

The following attestation bundles were made for webpush_rs-0.1.4-cp38-abi3-manylinux_2_28_x86_64.whl:

Publisher: release.yml on coseto6125/webpush-rs

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file webpush_rs-0.1.4-cp38-abi3-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for webpush_rs-0.1.4-cp38-abi3-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 472f95b8b40f135ad9c6e446dc9fe2e74bc0a1b15c86b5a2b9bf66b62bcd9659
MD5 0c17230f45e1330684c828d04e650a10
BLAKE2b-256 4051bc21a1807a7f5671c48adb09ae8e9de54c619f6be3abc1961ed5690ca881

See more details on using hashes here.

Provenance

The following attestation bundles were made for webpush_rs-0.1.4-cp38-abi3-manylinux_2_28_aarch64.whl:

Publisher: release.yml on coseto6125/webpush-rs

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file webpush_rs-0.1.4-cp38-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for webpush_rs-0.1.4-cp38-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 7aaadcfce995473e524534a0d219a7230d345ff96eb6be262289b6aa0f3b3275
MD5 95c187db4eb93b9a1011d35a2501c5c7
BLAKE2b-256 d2108a7c208a703f99d9fada796097a84c15ed006f4c98a497775e1df4d9d73e

See more details on using hashes here.

Provenance

The following attestation bundles were made for webpush_rs-0.1.4-cp38-abi3-macosx_11_0_arm64.whl:

Publisher: release.yml on coseto6125/webpush-rs

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file webpush_rs-0.1.4-cp38-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for webpush_rs-0.1.4-cp38-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 709f1716482992a5e2a7f0513d25eb43cadc26038359cb085e0a5ddda8573563
MD5 39e87409692a660623e33902c2cec425
BLAKE2b-256 0a2ef58bd14b44bcbd89b03c3272db5396bebb06373162e84567d3287d62f0ad

See more details on using hashes here.

Provenance

The following attestation bundles were made for webpush_rs-0.1.4-cp38-abi3-macosx_10_12_x86_64.whl:

Publisher: release.yml on coseto6125/webpush-rs

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.1.4 This release

6 files

0.1.1

5 files

0.1.0

5 files

Supported by

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