This release has been yanked by its maintainers, and will be ignored by installers, except when explicitly specified.
Reason given by maintainers: renamed to nn-webhooks-sdk
webhookd-sdk (Python)
Official Python SDK for NimbusNexus Webhooks — publish events, manage your endpoints / keys / deliveries, and verify the webhooks you receive.
pip install webhookd-sdk
Verify an incoming webhook (subscribers)
When webhookd delivers a webhook it signs the body with your endpoint's signing secret. Always verify the signature before trusting the payload — it proves the request really came from webhookd and wasn't tampered with or replayed.
from webhookd_sdk import verify
# In your webhook handler — pass the RAW request body bytes (do not re-serialize the JSON):
ok = verify(
secret=ENDPOINT_SIGNING_SECRET,
raw_body=request.body,
signature=request.headers["X-Webhook-Signature"],
timestamp=request.headers["X-Webhook-Timestamp"],
)
if not ok:
return Response(status_code=400) # forged, tampered, or outside the 300s replay window
Publish an event (producers)
from webhookd_sdk import Client, WebhookdAPIError
with Client("https://webhooks.example.com", api_key="whsk_…") as wh:
try:
event = wh.publish(
"order.created",
{"order_id": "ord_123", "total": 4200},
idempotency_key="order-123", # makes the publish safe to retry
)
print(event.event_uid, event.deliveries_created)
except WebhookdAPIError as e:
print(e.status_code, e.code, e.message) # the stable {error:{code,message}} envelope
Transient failures (connection errors, 429, 5xx) are retried with backoff (a 429 honours
Retry-After); other 4xx raise WebhookdAPIError.
Manage endpoints, keys & deliveries (operators)
The same Client wraps the control-plane API — register receivers, mint keys, and drain the
dead-letter queue from code (needs an admin-scoped key). Management methods return the raw JSON as
dicts (snake_case, exactly as the API sends); list methods return a page —
{"items": [...], "next_offset": int | None}; delete/revoke return None (a 204).
from webhookd_sdk import Client
wh = Client("https://webhooks.example.com", api_key="whsk_admin_…")
# --- Endpoints ----------------------------------------------------------------
# Create a receiver — its signing secret is in the response exactly once, so persist it now.
ep = wh.create_endpoint(
"https://your-app.example/webhooks",
subscriptions=[{"match_kind": "prefix", "pattern": "order."}],
description="orders service",
)
endpoint_id, signing_secret = ep["id"], ep["secret"]
wh.list_endpoints(environment="prod") # {"items": [...], "next_offset": ...}
wh.get_endpoint(endpoint_id)
# PATCH — send only the keys you want to change (omitted = unchanged, None = cleared):
wh.update_endpoint(endpoint_id, {"max_attempts": 10, "status": "disabled"})
wh.rotate_endpoint_secret(endpoint_id) # returns the new secret, once
wh.enable_endpoint(endpoint_id) # recover an auto-disabled endpoint
wh.delete_endpoint(endpoint_id) # -> None (204)
# --- API keys -----------------------------------------------------------------
key = wh.create_api_key("ci-publisher", scope="publish", expires_in_days=90)
print(key["key"]) # shown once
wh.revoke_api_key(key["id"]) # -> None (204)
# --- Deliveries / dead-letter recovery ----------------------------------------
for d in wh.list_deliveries(status="dead")["items"]:
wh.redeliver(d["id"])
Develop
pip install -e '.[dev]'
pytest && ruff check . && mypy webhookd_sdk
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file webhookd_sdk-0.2.0.tar.gz.
File metadata
- Download URL: webhookd_sdk-0.2.0.tar.gz
- Upload date:
- Size: 13.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/6.1.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
29c975077cc652b4508812e4be1723302c362f5bcb5de0ce822262e50731932b
|
|
| MD5 |
cda5d6d64cd661216b60a8bdc3899dce
|
|
| BLAKE2b-256 |
83fbd921b44142edde35e271796dec862c90abc2cf064e7cbde1711c866c85d9
|
Provenance
The following attestation bundles were made for webhookd_sdk-0.2.0.tar.gz:
Publisher:
publish.yml on NimbusNexus/Webhooks-sdks
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
webhookd_sdk-0.2.0.tar.gz -
Subject digest:
29c975077cc652b4508812e4be1723302c362f5bcb5de0ce822262e50731932b - Sigstore transparency entry: 2203734107
- Sigstore integration time:
-
Permalink:
NimbusNexus/Webhooks-sdks@f56585acfa4ec8b978d3374a3c90e1d72c95b46e -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/NimbusNexus
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@f56585acfa4ec8b978d3374a3c90e1d72c95b46e -
Trigger Event:
push
-
Statement type:
File details
Details for the file webhookd_sdk-0.2.0-py3-none-any.whl.
File metadata
- Download URL: webhookd_sdk-0.2.0-py3-none-any.whl
- Upload date:
- Size: 10.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/6.1.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e91fbc0fe89cb84528e741c655e98e15fde68e014d84769da186092d3ba33c21
|
|
| MD5 |
87a0e878226310b40ba083ae2a6237b2
|
|
| BLAKE2b-256 |
69988cc4b286188a2e47fc2413eed384ea10316a4b7884ac125affda90a633c7
|
Provenance
The following attestation bundles were made for webhookd_sdk-0.2.0-py3-none-any.whl:
Publisher:
publish.yml on NimbusNexus/Webhooks-sdks
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
webhookd_sdk-0.2.0-py3-none-any.whl -
Subject digest:
e91fbc0fe89cb84528e741c655e98e15fde68e014d84769da186092d3ba33c21 - Sigstore transparency entry: 2203734150
- Sigstore integration time:
-
Permalink:
NimbusNexus/Webhooks-sdks@f56585acfa4ec8b978d3374a3c90e1d72c95b46e -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/NimbusNexus
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@f56585acfa4ec8b978d3374a3c90e1d72c95b46e -
Trigger Event:
push
-
Statement type: