Add Telegram Bot API 10.3 support - #88
Conversation
Replace flat ephemeral send fields with EphemeralMessageParameters and add rich-message buttons/documents, draft stop controls, and related update types. Co-authored-by: Cursor <cursoragent@cursor.com>
Add Telegram API field comments and align/style helpers on 10.3 types, use EphemeralMessageParameters as a value with AddInterfaceNonZero to match LinkPreviewOptions, gitignore .cursor agent config, and remove it from the tree. Co-authored-by: Cursor <cursoragent@cursor.com>
There was a problem hiding this comment.
Solid 10.3 work. I ran the parity suite against the updated 10.3 api.json — passes clean, the EphemeralMessageParameters migration covers exactly the 14 methods the spec lists, and the negative leak test (unsupported methods must not emit it) is still in place. I pushed 6e23f38 to the branch: a gofumpt pass over the three misaligned struct fields, nothing else.
One thing needs fixing before merge: sendVideoNote / sendLocation / sendVenue / sendContact now swallow the BaseChat.params() error — details and suggestions inline. The rest of the inline notes are small: pointer-vs-value asymmetry on EditEphemeralMessageTextConfig.RichMessage, a typed-nil media guard on the ephemeral media edit, a docs line recommending HTTP URLs the spec forbids, and two test-coverage gaps.
Non-blocker, for the record: docs/examples still stop at 10.2 — nothing yet on draft stop (CanStop/KeepOnStop + handling stopped_message_generation), ReplaceCallbackQueryMessage, rich buttons/documents, or can_send_welcome_messages. Fine as a follow-up PR.
Co-authored-by: Valeriy Selitskiy <239034+iamwavecut@users.noreply.github.com>
Replace flat ephemeral send fields with EphemeralMessageParameters and add rich-message buttons/documents, draft stop controls, and related update types.
Reopened after reverting merge of #87 on
master.Test plan
go vet ./...go test ./...go test -race ./...go test -tags=api_parity ./...Made with Cursor