Skip to main content

A Webhook publisher implementation for Swarmauri.

Project description

Swarmauri Logo

PyPI - Downloads Hits PyPI - Python Version PyPI - License PyPI - swarmauri_publisher_webhook


Swarmauri Webhook Publisher

WebhookPublisher is a Swarmauri component that delivers JSON events to an HTTP endpoint. It keeps an internal httpx.Client session for efficient reuse and raises a RuntimeError when the webhook cannot be reached or responds with a non-success status code.

Installation

Choose the tool that fits your workflow:

# pip
pip install swarmauri_publisher_webhook

# Poetry
poetry add swarmauri_publisher_webhook

# uv (install the tool if you do not already have it)
curl -LsSf https://astral.sh/uv/install.sh | sh
uv add swarmauri_publisher_webhook

Usage

from swarmauri_publisher_webhook import WebhookPublisher

publisher = WebhookPublisher(url="https://your-webhook-endpoint.com/hook")

publisher.publish(
    channel="my_data_stream",
    payload={"message": "Hello, webhook!", "value": 123}
)

The publisher posts a JSON object shaped as {"channel": ..., "payload": ...} to the configured URL. Wrap calls to publish in your own error handling if you need to catch connectivity or webhook-side failures.

Want to help?

If you want to contribute to swarmauri-sdk, read up on our guidelines for contributing that will help you get started.

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

swarmauri_publisher_webhook-0.3.0.dev45.tar.gz (3.2 kB view details)

Uploaded Source

Built Distribution

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

File details

Details for the file swarmauri_publisher_webhook-0.3.0.dev45.tar.gz.

File metadata

  • Download URL: swarmauri_publisher_webhook-0.3.0.dev45.tar.gz
  • Upload date:
  • Size: 3.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.12 {"installer":{"name":"uv","version":"0.10.12","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for swarmauri_publisher_webhook-0.3.0.dev45.tar.gz
Algorithm Hash digest
SHA256 8f0eb30ff89a792b2a3f6fcf3672280e373dbb7a74ca1fb264c7460138e732a7
MD5 7326df572272ddbd819c96c3d6ac4183
BLAKE2b-256 df8695023510bd3082176bc87c714932906c51a0b1fb1418ad84577a548db6ee

See more details on using hashes here.

File details

Details for the file swarmauri_publisher_webhook-0.3.0.dev45-py3-none-any.whl.

File metadata

  • Download URL: swarmauri_publisher_webhook-0.3.0.dev45-py3-none-any.whl
  • Upload date:
  • Size: 4.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.12 {"installer":{"name":"uv","version":"0.10.12","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for swarmauri_publisher_webhook-0.3.0.dev45-py3-none-any.whl
Algorithm Hash digest
SHA256 519453eaf6611a03c1e0f0387bf2d2730722588bd9b50e379a6610326998e47f
MD5 ddeb69c11cdc1cc404b089658043cb0d
BLAKE2b-256 51db42f8a94e9fb8ef873bfa228cc91078f476054d9fd07da8322ea26eaf2c74

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