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.dev31.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.dev31.tar.gz.

File metadata

  • Download URL: swarmauri_publisher_webhook-0.3.0.dev31.tar.gz
  • Upload date:
  • Size: 3.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.3 {"installer":{"name":"uv","version":"0.10.3","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.dev31.tar.gz
Algorithm Hash digest
SHA256 9cdd5903e400a323cd95b5fd4a54554dce749da111af1d02beceed3eea33d039
MD5 e02b493f8961560fa9689b658f0307ac
BLAKE2b-256 f61ea3e3e092011be23ddd6e66d209ea02c366bbabcadac7693e3abde335ad6c

See more details on using hashes here.

File details

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

File metadata

  • Download URL: swarmauri_publisher_webhook-0.3.0.dev31-py3-none-any.whl
  • Upload date:
  • Size: 4.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.3 {"installer":{"name":"uv","version":"0.10.3","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.dev31-py3-none-any.whl
Algorithm Hash digest
SHA256 eb5e111a5ca9eb270c4699278c85f0be16dc8cb3555be732d9e4e3de61b7d839
MD5 e9b3a78309d79f4a04f43b7b9f366e9f
BLAKE2b-256 8a2c285945889b3dc128b92fa9a3b7accc8bb3cb6140d85cf67296fbeecb7be1

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