Skip to content

channel-telegram

Sends delivery notifications through the Telegram Bot API (sendMessage, plain text), registered as the telegram channel in the delivery system. Tenant-owned chat target: reach it only via ctx.notify(type, { route: { telegram: "<chat id or @channel>" } }). The bot token is the tenant secret channel-telegram:secret:bot-token; the token never reaches logs or delivery attempts. Requires delivery and secrets. The API base URL, its host allowlist (allowedHosts, default api.telegram.org), requireHttps (default true; boot fails on a mismatch) and the request timeout are app options of createChannelTelegramFeature(opts), never tenant config.

What this feature needs to run (Requires).

flowchart TB
  n_channel_telegram["channel-telegram"]
  subgraph how_reqs["Requires"]
    n_delivery["delivery"]
    n_secrets["secrets"]
  end
  n_delivery --> n_channel_telegram
  n_secrets --> n_channel_telegram
SecretScopeHint
channel-telegram:secret:bot-tokentenantToken from @BotFather. Used for every Telegram chat the tenant addresses via route: { telegram: “<chat id>” }.
  • Registers extension: deliveryChannel → telegram