The connector sent title and body as one sendMessage, so any notification
over Telegram's 4096 UTF-16 unit limit was refused with 'message is too
long' and, because a delivery is retried until the channel confirms it,
retried every ten minutes for ever without ever arriving. The chat channel
had its own splitter; both now share one in sdk/telegramtext, which counts
UTF-16 units rather than runes so an emoji-heavy body isn't over the limit
either.
The bundled internal/channels/telegram package (17 files) is deleted; the
channel now ships as archipelago/channels/telegram, launched by archiemessaging
through the existing channel-extension machinery. An existing [chat.telegram]
config enables it with the same keys: the token stays a secret reference
(token_ref) the host resolves, allowed_user_ids and show_tool_calls map onto
extension settings. Per-org bots compose the same extension per org from the
org's credential binding. Reload support is now derived from a channels.Reloader
interface instead of a *telegram.Gateway assertion. The five host-only seams
(/update, release announcements, running versions, in-place show_tool_calls,
reload) are dropped from the channel and need a contract home or deletion.
A gateway or SMTP failure skipped the message for the life of the process,
so mail sent during an outage was never answered. Only mail the channel
rejects is skipped now; the rest is retried on the next poll, and the
Message-ID as the source id makes the gateway replay a reply it already
produced instead of running the turn twice. Out-of-office replies, bulk and
list mail are ignored and replies are marked Auto-Submitted, so the channel
cannot loop with an auto-responder. Replies carry References for threading,
and port 465 uses implicit TLS.
The channel ran a hand-written SMTP listener and trusted the From address,
so anyone reaching the port could act as any user. It now uses go-imap,
go-message, go-msgauth and go-smtp; settings change accordingly.