Skip to content

fix(send_message): support Telegram rich messages - #46438

Closed
tsale wants to merge 1 commit into
NousResearch:mainfrom
tsale:fix/send-message-telegram-rich-standalone
Closed

fix(send_message): support Telegram rich messages#46438
tsale wants to merge 1 commit into
NousResearch:mainfrom
tsale:fix/send-message-telegram-rich-standalone

Conversation

@tsale

@tsale tsale commented Jun 15, 2026

Copy link
Copy Markdown

Summary

  • add an opt-in Telegram sendRichMessage fast path to the standalone send_message tool
  • pass raw Markdown to Telegram rich messages so tables, task lists, headings, and other Bot API 10.1 constructs render natively
  • fall back to legacy MarkdownV2 only on rich parser/capability failures, while avoiding legacy duplicate sends on transient rich failures
  • coerce string config values like "false"/"true" correctly for platforms.telegram.extra.rich_messages

Fixes #45854.

Notes

This keeps the tool/cron path aligned with the gateway rich-message opt-in behavior without changing the default: rich messages remain disabled unless platforms.telegram.extra.rich_messages: true is configured.

Test plan

  • uv run --extra dev --extra messaging python -m pytest tests/tools/test_send_message_tool.py -q -o addopts=
  • git diff --check
  • uv run python -m py_compile tools/send_message_tool.py tests/tools/test_send_message_tool.py

@alt-glitch alt-glitch added type/bug Something isn't working comp/tools Tool registry, model_tools, toolsets platform/telegram Telegram bot adapter P2 Medium — degraded but workaround exists duplicate This issue or pull request already exists labels Jun 15, 2026
@alt-glitch

Copy link
Copy Markdown
Collaborator

Duplicate of #46118 — both add an opt-in Telegram sendRichMessage fast-path to the standalone send_message tool (Fixes #45854). #46118 is the earliest open same-approach PR. Related: #46263 (same standalone-tool opt-in), #46317 (gateway opt-in).

@tsale tsale closed this Jun 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/tools Tool registry, model_tools, toolsets duplicate This issue or pull request already exists P2 Medium — degraded but workaround exists platform/telegram Telegram bot adapter type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Feature Request: Add sendRichMessage support to send_message tool for Telegram

2 participants