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

File metadata

  • Download URL: swarmauri_publisher_webhook-0.3.0.dev43.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.dev43.tar.gz
Algorithm Hash digest
SHA256 d0af0e7479e42956a1f1e7e38cb0ef9f01180f82addb99dd835f958ddb878c59
MD5 42b200717310731e557973e1194afbb6
BLAKE2b-256 81afb12bac8319468baed26aab6fbe93fec28c71e9556faf78d1ab81280839c7

See more details on using hashes here.

File details

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

File metadata

  • Download URL: swarmauri_publisher_webhook-0.3.0.dev43-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.dev43-py3-none-any.whl
Algorithm Hash digest
SHA256 353ff28bb390ef4f8ed5a0c67373c492ab0347852648ffa4374c249b52864521
MD5 d5a427675d23320306ee08d61f88abcb
BLAKE2b-256 c951ca3bfc1742d3ed27570b45d15c7dd6d7dca9cda671302e81600e3bf2c898

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