Skip to content

Bot API 10.2 - #275

Open
mario-amazing wants to merge 1 commit into
telegram-bot-rb:masterfrom
mario-amazing:bot-api-10.2
Open

mario-amazing wants to merge 1 commit into
telegram-bot-rb:masterfrom
mario-amazing:bot-api-10.2

Conversation

@mario-amazing

Copy link
Copy Markdown
Contributor

Updates the client to Bot API 10.2 (July 14, 2026).

What's included

  • Regenerated method and payload-type lists via bin/fetch-telegram-methods.
    New helper methods now include sendRichMessage / sendRichMessageDraft,
    the ephemeral-message editing/deletion methods
    (editEphemeralMessageText/Media/Caption/ReplyMarkup, deleteEphemeralMessage),
    sendLivePhoto, answerGuestQuery, deleteMessageReaction,
    deleteAllMessageReactions, managed-bot access settings, and more.
    payload_types.txt gains guest_message (10.0) and subscription (10.2).

  • Nested file uploads for sendRichMessage. Rich messages carry media
    (photos/videos/etc.) deep inside rich_message.blocks[] and
    rich_message.media[], so the existing one-level file extractor could not reach
    them. extract_files_from_hash now recurses through nested hashes and arrays,
    and sendRichMessage is wired through extract_files_from_field!(:rich_message).
    The behaviour of sendMediaGroup / editMessageMedia / postStory is
    unchanged (their structures are one level deep).

  • guest_message and subscription are added to the typed_update_spec
    exclusion list, mirroring how managed_bot was handled in the 9.6 bump, since
    telegram-bot-types does not define those classes yet.

Tests

  • New RequestBodyFormatter specs cover deep extraction from rich message blocks
    (with and without files).
  • Full suite green: 352 examples, 0 failures; RuboCop clean.

🤖 Generated with Claude Code

- Regenerate api_methods.txt and payload_types.txt via bin/fetch-telegram-methods
  (adds Rich Messages, Ephemeral Messages, Guest/Community/subscription updates,
  live photos, reaction-deletion methods, and more)
- Extract File uploads nested inside rich message blocks for sendRichMessage by
  making the file extractor recurse through nested hashes and arrays

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant