Sendblue iMessage webhook channel for Zeno.
Project description
zeno-channel-sendblue
Sendblue iMessage webhook channel for Zeno. The first
webhook-style channel — use it as the template for any Channel that
hosts its own HTTP inbound transport.
Hosts a Starlette + uvicorn server for Sendblue's inbound webhook and posts outbound messages to Sendblue's REST API. Verifies the shared-secret header, enforces a phone-number allowlist, and fires a typing indicator per accepted inbound message.
Install
uv add 'zeno-framework[sendblue]'
# or, without the AI package:
uv add zeno-channel-sendblue
Minimal usage
from zeno.channels.sendblue.channel import SendblueChannel
channel = SendblueChannel(
api_key_id="...",
api_secret="...",
from_number="+15550001111",
signing_secret="...", # shared with Sendblue dashboard
allowed_numbers=("+31600000000",),
host="127.0.0.1",
port=8080,
webhook_path="/webhook",
)
# Then pass it to ZenoApp(channels=[channel]) exactly like any Channel.
See apps/zeno-example-imessage
for the complete runnable reference app, including ngrok / Cloudflare
Tunnel setup notes.
Behavior
- Signature verification: Sendblue echoes the configured secret in
the
sb-signing-secretheader. Bad or missing signature →401. Every other drop (non-iMessage service, group message, unallowlisted sender, malformed JSON, queue full) returns200so Sendblue doesn't retry and so the 401 audit signal stays meaningful. - Inbound →
IncomingMessage:user_id = from_number(E.164),text = content,thread_key = from_numberso replies route back. A non-emptymedia_urlbecomes an imageAttachment. - Outbound: text + optional single image via
POST /api/send-message. Content over 18,996 chars is truncated (WARNING log) to fit Sendblue's limit. - Capabilities:
supports_images=True,supports_typing=True, others False.
Testing
uv run pytest packages/zeno-channel-sendblue
Tests use httpx.MockTransport for outbound and the Starlette
TestClient for the router. No Sendblue secrets required in CI.
Part of the Zeno framework.
Project details
Release history Release notifications | RSS feed
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 zeno_channel_sendblue-1.0.1.tar.gz.
File metadata
- Download URL: zeno_channel_sendblue-1.0.1.tar.gz
- Upload date:
- Size: 13.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9658c67e6a960d0d24ebc84a2aa7cd62baa51ae83c9141da991d2c50bc031008
|
|
| MD5 |
0072f0c23083861888f82706a2e794c7
|
|
| BLAKE2b-256 |
ea04bcb9825fb4af8c98c8adc4c0d0b751b1158e39d7715dd85a0122536502da
|
Provenance
The following attestation bundles were made for zeno_channel_sendblue-1.0.1.tar.gz:
Publisher:
publish.yml on nkootstra/zeno
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
zeno_channel_sendblue-1.0.1.tar.gz -
Subject digest:
9658c67e6a960d0d24ebc84a2aa7cd62baa51ae83c9141da991d2c50bc031008 - Sigstore transparency entry: 1390034372
- Sigstore integration time:
-
Permalink:
nkootstra/zeno@d2cdcd756fc7ca022ec23fe9ef35d76e7683ac9c -
Branch / Tag:
refs/tags/v1.0.1 - Owner: https://github.com/nkootstra
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@d2cdcd756fc7ca022ec23fe9ef35d76e7683ac9c -
Trigger Event:
push
-
Statement type:
File details
Details for the file zeno_channel_sendblue-1.0.1-py3-none-any.whl.
File metadata
- Download URL: zeno_channel_sendblue-1.0.1-py3-none-any.whl
- Upload date:
- Size: 11.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a4427eb153cb4af5ead8e66bef30d20163b622cd99a84b740fe5909933d3bff8
|
|
| MD5 |
ee1cf006b7091da0045f09a668809c6f
|
|
| BLAKE2b-256 |
90850e3014b7900a21518d281ec3460306d5d32d02e417686551e3360a93185c
|
Provenance
The following attestation bundles were made for zeno_channel_sendblue-1.0.1-py3-none-any.whl:
Publisher:
publish.yml on nkootstra/zeno
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
zeno_channel_sendblue-1.0.1-py3-none-any.whl -
Subject digest:
a4427eb153cb4af5ead8e66bef30d20163b622cd99a84b740fe5909933d3bff8 - Sigstore transparency entry: 1390034446
- Sigstore integration time:
-
Permalink:
nkootstra/zeno@d2cdcd756fc7ca022ec23fe9ef35d76e7683ac9c -
Branch / Tag:
refs/tags/v1.0.1 - Owner: https://github.com/nkootstra
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@d2cdcd756fc7ca022ec23fe9ef35d76e7683ac9c -
Trigger Event:
push
-
Statement type: