Channels
SMS
Twilio form webhook signed with X-Twilio-Signature. The URL in add() must be the public URL Twilio signed (same value as SMS_WEBHOOK_URL). Signature fail-closes without webhook_url + auth_token.
export TWILIO_ACCOUNT_SID='…'
export TWILIO_AUTH_TOKEN='…'
export TWILIO_FROM='+1…'
export SMS_WEBHOOK_URL='https://…/sms'
export PORT=8080cx.channels.add(
"sms",
via="self-host",
account_sid=account_sid,
auth_token=auth_token,
from_number=from_number,
webhook_url=webhook_url,
bot_token="local",
)
# POST form → cx.handle("sms", body, headers)await cx.channels.add("sms", {
via: "self-host",
account_sid,
auth_token,
from_number,
webhook_url,
bot_token: "local",
})
// POST form → await cx.handle("sms", body, headers)What it can do
Plans Post, Reply, and SendMedia only. No buttons, pin, or react. Adapters degrade buttons to a numbered list if you pass them anyway.