hegemony-notification-sdk
Public, dependency-light SDK for building Hegemony notification plugins — out-of-tree wheels that add notification destination types to the core platform at runtime.
A plugin depends only on this package (which depends only on pydantic) and
exposes a register(registry) callable under the
hegemony.notification_providers entry-point group:
# In your plugin's pyproject.toml
[project]
dependencies = ["hegemony-notification-sdk>=0.3,<0.4"]
[project.entry-points."hegemony.notification_providers"]
my_plugin = "my_plugin:register"
The SDK is released together with the plugins in this repository, as a wheel attached to each GitHub release; it is not published on PyPI. While the major version is 0, an incompatible change to the contract is released as a new minor version, so depend on one minor line. The repository README walks through a complete transport and how to install a plugin into a Hegemony instance.
Presets (recommended)
The simplest way to add a user-friendly channel is a preset over an existing
transport. The plugin contributes a friendly config_schema and a pure
build_config that rewrites the friendly fields into the base transport's
config. Secret references pass through untouched — the host's base transport
resolves them at send time, so the plugin never handles secrets or performs I/O.
# my_plugin/__init__.py
from hegemony_notification_sdk import NotificationPluginRegistry
def register(registry: NotificationPluginRegistry) -> None:
registry.register_preset(
destination_type="telegram",
display_name="Telegram",
description="Send via a Telegram bot.",
base_transport="shoutrrr",
build_config=lambda cfg: {
"url_secret": f"telegram://{cfg['token']}@telegram?chats={cfg['chats']}"
},
config_schema={
"type": "object",
"required": ["token", "chats"],
"properties": {
"token": {"type": "string", "title": "Bot token (secret reference)"},
"chats": {"type": "string", "title": "Chat IDs (comma-separated)"},
},
},
)
Native transports
For channels that cannot be expressed as a preset, register a native
destination type with its own send coroutine via
register_destination_type(...).
ABI
SDK_ABI_VERSION is bumped only on incompatible changes to the registration
contract. The platform exposes its value as registry.api_version so a plugin
can self-gate if needed.
Metadata
Release files for hegemony-notification-sdk 0.3.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| hegemony_notification_sdk-0.3.3-py3-none-any.whl | Python 3 | none | any | Details for hegemony_notification_sdk-0.3.3-py3-none-any.whl |
Release files / hegemony_notification_sdk-0.3.3-py3-none-any.whl
| Download URL | hegemony_notification_sdk-0.3.3-py3-none-any.whl |
|---|---|
| Size | 18.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5547bb4425020a675b872fe8ab512e1dbaf6b44a21e7e03b92071713f736909b
|
|
BLAKE2b-256 checksum How to use checksums |
d20af3a1b3513facb755cf59373c975a01c37e42dc055933babfa12450740718
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.10.12
|
Security for hegemony-notification-sdk 0.3.3
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.
To learn more about protecting yourself from malicious actors, visit our package security documentation.