From 972b7ec50a4da8a06c182e35688856a73cc70a3e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 22 May 2026 17:02:53 +0000 Subject: [PATCH] chore(deps): bump github.com/go-telegram/bot from 1.20.0 to 1.21.0 Bumps [github.com/go-telegram/bot](https://github.com/go-telegram/bot) from 1.20.0 to 1.21.0. - [Release notes](https://github.com/go-telegram/bot/releases) - [Changelog](https://github.com/go-telegram/bot/blob/main/CHANGELOG.md) - [Commits](https://github.com/go-telegram/bot/compare/v1.20.0...v1.21.0) --- updated-dependencies: - dependency-name: github.com/go-telegram/bot dependency-version: 1.21.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 4 +- .../github.com/go-telegram/bot/CHANGELOG.md | 4 + vendor/github.com/go-telegram/bot/README.md | 2 +- vendor/github.com/go-telegram/bot/bot.go | 10 +- .../go-telegram/bot/build_request_form.go | 30 ++- vendor/github.com/go-telegram/bot/methods.go | 60 ++++++ .../go-telegram/bot/methods_params.go | 171 +++++++++++++----- .../github.com/go-telegram/bot/models/chat.go | 3 +- .../go-telegram/bot/models/chat_member.go | 1 + .../github.com/go-telegram/bot/models/gift.go | 12 +- .../go-telegram/bot/models/guest_live.go | 37 ++++ .../go-telegram/bot/models/input_media.go | 119 ++++++++++++ .../go-telegram/bot/models/managed_bot.go | 24 +++ .../go-telegram/bot/models/message.go | 16 +- .../go-telegram/bot/models/message_entity.go | 12 +- .../github.com/go-telegram/bot/models/poll.go | 78 +++++++- .../go-telegram/bot/models/reply.go | 2 + .../go-telegram/bot/models/reply_markup.go | 21 ++- .../go-telegram/bot/models/update.go | 4 + .../github.com/go-telegram/bot/models/user.go | 30 +-- .../go-telegram/bot/models/voice_chat.go | 21 --- vendor/modules.txt | 2 +- 23 files changed, 539 insertions(+), 126 deletions(-) create mode 100644 vendor/github.com/go-telegram/bot/models/guest_live.go create mode 100644 vendor/github.com/go-telegram/bot/models/managed_bot.go delete mode 100644 vendor/github.com/go-telegram/bot/models/voice_chat.go diff --git a/go.mod b/go.mod index 494b693..ce871f3 100644 --- a/go.mod +++ b/go.mod @@ -3,7 +3,7 @@ module github.com/YukariExpress/pgb go 1.26 require ( - github.com/go-telegram/bot v1.20.0 + github.com/go-telegram/bot v1.21.0 github.com/sethvargo/go-envconfig v1.3.0 github.com/stretchr/testify v1.11.1 ) diff --git a/go.sum b/go.sum index d2e2fe4..e1343c6 100644 --- a/go.sum +++ b/go.sum @@ -1,7 +1,7 @@ github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/go-telegram/bot v1.20.0 h1:4Pea/qTidSspr4WBJw9FbHUMNhYeqszBqQUfsQEyFbc= -github.com/go-telegram/bot v1.20.0/go.mod h1:i2TRs7fXWIeaceF3z7KzsMt/he0TwkVC680mvdTFYeM= +github.com/go-telegram/bot v1.21.0 h1:Va/PbGc2vBDdv57GCUEEVV6ROlHWiC6SklJY9Hvhzps= +github.com/go-telegram/bot v1.21.0/go.mod h1:i2TRs7fXWIeaceF3z7KzsMt/he0TwkVC680mvdTFYeM= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= diff --git a/vendor/github.com/go-telegram/bot/CHANGELOG.md b/vendor/github.com/go-telegram/bot/CHANGELOG.md index 19d87d9..dcd50ed 100644 --- a/vendor/github.com/go-telegram/bot/CHANGELOG.md +++ b/vendor/github.com/go-telegram/bot/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## v1.21.0 (2026-05-22) + +- Support Bot API 9.6 & 10.0, multipart fixes — closes #279 #280, fixes #273 #274 #271 #277 (#281) + ## v1.20.0 (2026-03-19) - resolve issues #242, #245, #261, #262 diff --git a/vendor/github.com/go-telegram/bot/README.md b/vendor/github.com/go-telegram/bot/README.md index b005ef2..18c6f34 100644 --- a/vendor/github.com/go-telegram/bot/README.md +++ b/vendor/github.com/go-telegram/bot/README.md @@ -6,7 +6,7 @@ > [Telegram Group](https://t.me/gotelegrambotui) -> Supports Bot API version: [9.5](https://core.telegram.org/bots/api#march-1-2026) from March 1, 2026 +> Supports Bot API version: [10.0](https://core.telegram.org/bots/api#may-8-2026) from May 8, 2026 It's a Go zero-dependencies telegram bot framework diff --git a/vendor/github.com/go-telegram/bot/bot.go b/vendor/github.com/go-telegram/bot/bot.go index c9ae9da..a17e4e6 100644 --- a/vendor/github.com/go-telegram/bot/bot.go +++ b/vendor/github.com/go-telegram/bot/bot.go @@ -101,14 +101,10 @@ func New(token string, options ...Option) (*Bot, error) { return b, nil } -// ID returns the bot ID +// ID returns the bot user id from the token prefix (":"). func (b *Bot) ID() int64 { - id, err := strconv.ParseInt(strings.Split(b.token, ":")[0], 10, 64) - if err != nil { - return 0 - } - - return id + i, _ := strconv.ParseInt(strings.Split(b.token, ":")[0], 10, 64) + return i } // SetToken sets the bot token diff --git a/vendor/github.com/go-telegram/bot/build_request_form.go b/vendor/github.com/go-telegram/bot/build_request_form.go index 2d3a5fb..a62f769 100644 --- a/vendor/github.com/go-telegram/bot/build_request_form.go +++ b/vendor/github.com/go-telegram/bot/build_request_form.go @@ -88,6 +88,8 @@ func buildRequestForm(form *multipart.Writer, params any) (int, error) { err = addFormFieldInputFileUpload(form, fieldName, vv) case *models.InputFileString: err = addFormFieldString(form, fieldName, vv.Data) + case *models.InputMediaLivePhoto: + err = addFormFieldInputMedia(form, fieldName, vv) case []models.InputMedia: var ss []inputMedia for _, m := range vv { @@ -117,8 +119,21 @@ func buildRequestForm(form *multipart.Writer, params any) (int, error) { return fieldsCount, nil } +func readerIsNil(r io.Reader) bool { + if r == nil { + return true + } + v := reflect.ValueOf(r) + switch v.Kind() { + case reflect.Pointer, reflect.Interface, reflect.Map, reflect.Slice, reflect.Chan, reflect.Func: + return v.IsNil() + default: + return false + } +} + func addFormFieldInputFileUpload(form *multipart.Writer, fieldName string, value *models.InputFileUpload) error { - if value.Data == nil || reflect.ValueOf(value.Data).IsNil() { + if readerIsNil(value.Data) { return fmt.Errorf("nil data for field %s", fieldName) } w, errCreateField := form.CreateFormFile(fieldName, value.Filename) @@ -141,6 +156,19 @@ func addFormFieldInputMediaItem(form *multipart.Writer, value inputMedia) ([]byt return nil, errCopy } } + if live, ok := value.(*models.InputMediaLivePhoto); ok && strings.HasPrefix(live.Photo, "attach://") { + filename := strings.TrimPrefix(live.Photo, "attach://") + if readerIsNil(live.PhotoAttachment) { + return nil, fmt.Errorf("nil PhotoAttachment for attach://%s", filename) + } + photoField, errCreate := form.CreateFormFile(filename, filename) + if errCreate != nil { + return nil, errCreate + } + if _, err := io.Copy(photoField, live.PhotoAttachment); err != nil { + return nil, err + } + } return value.MarshalInputMedia() } diff --git a/vendor/github.com/go-telegram/bot/methods.go b/vendor/github.com/go-telegram/bot/methods.go index 9869f05..352d95a 100644 --- a/vendor/github.com/go-telegram/bot/methods.go +++ b/vendor/github.com/go-telegram/bot/methods.go @@ -1166,3 +1166,63 @@ func (b *Bot) SetChatMemberTag(ctx context.Context, params *SetChatMemberTagPara err := b.rawRequest(ctx, "setChatMemberTag", params, &result) return result, err } + +func (b *Bot) GetManagedBotToken(ctx context.Context, params *GetManagedBotTokenParams) (string, error) { + var result string + err := b.rawRequest(ctx, "getManagedBotToken", params, &result) + return result, err +} + +func (b *Bot) ReplaceManagedBotToken(ctx context.Context, params *ReplaceManagedBotTokenParams) (string, error) { + var result string + err := b.rawRequest(ctx, "replaceManagedBotToken", params, &result) + return result, err +} + +func (b *Bot) SavePreparedKeyboardButton(ctx context.Context, params *SavePreparedKeyboardButtonParams) (*models.PreparedKeyboardButton, error) { + result := &models.PreparedKeyboardButton{} + err := b.rawRequest(ctx, "savePreparedKeyboardButton", params, result) + return result, err +} + +func (b *Bot) AnswerGuestQuery(ctx context.Context, params *AnswerGuestQueryParams) (*models.SentGuestMessage, error) { + result := &models.SentGuestMessage{} + err := b.rawRequest(ctx, "answerGuestQuery", params, result) + return result, err +} + +func (b *Bot) DeleteAllMessageReactions(ctx context.Context, params *DeleteAllMessageReactionsParams) (bool, error) { + var result bool + err := b.rawRequest(ctx, "deleteAllMessageReactions", params, &result) + return result, err +} + +func (b *Bot) DeleteMessageReaction(ctx context.Context, params *DeleteMessageReactionParams) (bool, error) { + var result bool + err := b.rawRequest(ctx, "deleteMessageReaction", params, &result) + return result, err +} + +func (b *Bot) SendLivePhoto(ctx context.Context, params *SendLivePhotoParams) (*models.Message, error) { + result := &models.Message{} + err := b.rawRequest(ctx, "sendLivePhoto", params, result) + return result, err +} + +func (b *Bot) GetManagedBotAccessSettings(ctx context.Context, params *GetManagedBotAccessSettingsParams) (*models.BotAccessSettings, error) { + result := &models.BotAccessSettings{} + err := b.rawRequest(ctx, "getManagedBotAccessSettings", params, result) + return result, err +} + +func (b *Bot) SetManagedBotAccessSettings(ctx context.Context, params *SetManagedBotAccessSettingsParams) (bool, error) { + var result bool + err := b.rawRequest(ctx, "setManagedBotAccessSettings", params, &result) + return result, err +} + +func (b *Bot) GetUserPersonalChatMessages(ctx context.Context, params *GetUserPersonalChatMessagesParams) ([]models.Message, error) { + var result []models.Message + err := b.rawRequest(ctx, "getUserPersonalChatMessages", params, &result) + return result, err +} diff --git a/vendor/github.com/go-telegram/bot/methods_params.go b/vendor/github.com/go-telegram/bot/methods_params.go index 66ccd31..f3d3098 100644 --- a/vendor/github.com/go-telegram/bot/methods_params.go +++ b/vendor/github.com/go-telegram/bot/methods_params.go @@ -374,35 +374,46 @@ type SendContactParams struct { // SendPollParams https://core.telegram.org/bots/api#sendpoll type SendPollParams struct { - BusinessConnectionID string `json:"business_connection_id,omitempty"` - ChatID any `json:"chat_id"` - MessageThreadID int `json:"message_thread_id,omitempty"` - Question string `json:"question"` - QuestionParseMode models.ParseMode `json:"question_parse_mode,omitempty"` - QuestionEntities []models.MessageEntity `json:"question_entities,omitempty"` - Options []models.InputPollOption `json:"options"` - IsAnonymous *bool `json:"is_anonymous,omitempty"` - Type string `json:"type,omitempty"` - AllowsMultipleAnswers bool `json:"allows_multiple_answers,omitempty"` - CorrectOptionID int `json:"correct_option_id"` - Explanation string `json:"explanation,omitempty"` - ExplanationParseMode string `json:"explanation_parse_mode,omitempty"` - ExplanationEntities []models.MessageEntity `json:"explanation_entities,omitempty"` - OpenPeriod int `json:"open_period,omitempty"` - CloseDate int `json:"close_date,omitempty"` - IsClosed bool `json:"is_closed,omitempty"` - DisableNotification bool `json:"disable_notification,omitempty"` - ProtectContent bool `json:"protect_content,omitempty"` - AllowPaidBroadcast bool `json:"allow_paid_broadcast,omitempty"` - MessageEffectID string `json:"message_effect_id,omitempty"` - ReplyParameters *models.ReplyParameters `json:"reply_parameters,omitempty"` - ReplyMarkup models.ReplyMarkup `json:"reply_markup,omitempty"` + BusinessConnectionID string `json:"business_connection_id,omitempty"` + ChatID any `json:"chat_id"` + MessageThreadID int `json:"message_thread_id,omitempty"` + Question string `json:"question"` + QuestionParseMode models.ParseMode `json:"question_parse_mode,omitempty"` + QuestionEntities []models.MessageEntity `json:"question_entities,omitempty"` + Options []models.InputPollOption `json:"options"` + IsAnonymous *bool `json:"is_anonymous,omitempty"` + Type string `json:"type,omitempty"` + AllowsMultipleAnswers bool `json:"allows_multiple_answers,omitempty"` + CorrectOptionIDs []int `json:"correct_option_ids,omitempty"` + Explanation string `json:"explanation,omitempty"` + ExplanationParseMode string `json:"explanation_parse_mode,omitempty"` + ExplanationEntities []models.MessageEntity `json:"explanation_entities,omitempty"` + Description string `json:"description,omitempty"` + DescriptionParseMode models.ParseMode `json:"description_parse_mode,omitempty"` + DescriptionEntities []models.MessageEntity `json:"description_entities,omitempty"` + Media models.InputMedia `json:"media,omitempty"` + ExplanationMedia models.InputMedia `json:"explanation_media,omitempty"` + MembersOnly bool `json:"members_only,omitempty"` + CountryCodes []string `json:"country_codes,omitempty"` + AllowsRevoting bool `json:"allows_revoting,omitempty"` + ShuffleOptions bool `json:"shuffle_options,omitempty"` + AllowAddingOptions bool `json:"allow_adding_options,omitempty"` + HideResultsUntilCloses bool `json:"hide_results_until_closes,omitempty"` + OpenPeriod int `json:"open_period,omitempty"` + CloseDate int `json:"close_date,omitempty"` + IsClosed bool `json:"is_closed,omitempty"` + DisableNotification bool `json:"disable_notification,omitempty"` + ProtectContent bool `json:"protect_content,omitempty"` + AllowPaidBroadcast bool `json:"allow_paid_broadcast,omitempty"` + MessageEffectID string `json:"message_effect_id,omitempty"` + ReplyParameters *models.ReplyParameters `json:"reply_parameters,omitempty"` + ReplyMarkup models.ReplyMarkup `json:"reply_markup,omitempty"` } // SendChecklistParams https://core.telegram.org/bots/api#sendchecklist type SendChecklistParams struct { BusinessConnectionID string `json:"business_connection_id,omitempty"` - ChatID int `json:"chat_id"` + ChatID any `json:"chat_id"` Checklist models.InputChecklist `json:"checklist"` DisableNotification bool `json:"disable_notification,omitempty"` ProtectContent bool `json:"protect_content,omitempty"` @@ -509,13 +520,13 @@ type SetChatAdministratorCustomTitleParams struct { } type BanChatSenderChatParams struct { - ChatID any `json:"chat_id"` - SenderChatID int `json:"sender_chat_id"` + ChatID any `json:"chat_id"` + SenderChatID int64 `json:"sender_chat_id"` } type UnbanChatSenderChatParams struct { - ChatID any `json:"chat_id"` - SenderChatID int `json:"sender_chat_id"` + ChatID any `json:"chat_id"` + SenderChatID int64 `json:"sender_chat_id"` } type SetChatPermissionsParams struct { @@ -616,7 +627,8 @@ type GetChatParams struct { } type GetChatAdministratorsParams struct { - ChatID any `json:"chat_id"` + ChatID any `json:"chat_id"` + ReturnBots *bool `json:"return_bots,omitempty"` } type GetChatMemberCountParams struct { @@ -815,7 +827,7 @@ type EditMessageMediaParams struct { // EditMessageChecklistParams https://core.telegram.org/bots/api#editmessagechecklist type EditMessageChecklistParams struct { BusinessConnectionID string `json:"business_connection_id,omitempty"` - ChatID int `json:"chat_id,omitempty"` + ChatID int64 `json:"chat_id,omitempty"` MessageID int `json:"message_id,omitempty"` Checklist models.InputChecklist `json:"checklist"` ReplyMarkup models.ReplyMarkup `json:"reply_markup,omitempty"` @@ -838,14 +850,14 @@ type StopPollParams struct { // ApproveSuggestedPostParams https://core.telegram.org/bots/api#approvesuggestedpost type ApproveSuggestedPostParams struct { - ChatID int `json:"chat_id"` - MessageID int `json:"message_id"` - SendDate int `json:"send_date,omitempty"` + ChatID int64 `json:"chat_id"` + MessageID int `json:"message_id"` + SendDate int `json:"send_date,omitempty"` } // DeclineSuggestedPostParams https://core.telegram.org/bots/api#declinesuggestedpost type DeclineSuggestedPostParams struct { - ChatID int `json:"chat_id"` + ChatID int64 `json:"chat_id"` MessageID int `json:"message_id"` Comment string `json:"comment,omitempty"` } @@ -1146,7 +1158,7 @@ type RemoveChatVerificationParams struct { // ReadBusinessMessageParams https://core.telegram.org/bots/api#readbusinessmessage type ReadBusinessMessageParams struct { BusinessConnectionID string `json:"business_connection_id"` - ChatID int `json:"chat_id"` + ChatID int64 `json:"chat_id"` MessageID int `json:"message_id"` } @@ -1208,17 +1220,17 @@ type TransferBusinessAccountStarsParams struct { // GetBusinessAccountGiftsParams https://core.telegram.org/bots/api#getbusinessaccountgifts type GetBusinessAccountGiftsParams struct { - BusinessConnectionID string `json:"business_connection_id"` - ExcludeUnsaved bool `json:"exclude_unsaved,omitempty"` - ExcludeSaved bool `json:"exclude_saved,omitempty"` - ExcludeUnlimited bool `json:"exclude_unlimited,omitempty"` - ExcludeLimitedUpgradable bool `json:"exclude_limited_upgradable,omitempty"` + BusinessConnectionID string `json:"business_connection_id"` + ExcludeUnsaved bool `json:"exclude_unsaved,omitempty"` + ExcludeSaved bool `json:"exclude_saved,omitempty"` + ExcludeUnlimited bool `json:"exclude_unlimited,omitempty"` + ExcludeLimitedUpgradable bool `json:"exclude_limited_upgradable,omitempty"` ExcludeLimitedNonUpgradable bool `json:"exclude_limited_non_upgradable,omitempty"` - ExcludeUnique bool `json:"exclude_unique,omitempty"` - ExcludeFromBlockchain bool `json:"exclude_from_blockchain,omitempty"` - SortByPrice bool `json:"sort_by_price,omitempty"` - Offset string `json:"offset,omitempty"` - Limit int `json:"limit,omitempty"` + ExcludeUnique bool `json:"exclude_unique,omitempty"` + ExcludeFromBlockchain bool `json:"exclude_from_blockchain,omitempty"` + SortByPrice bool `json:"sort_by_price,omitempty"` + Offset string `json:"offset,omitempty"` + Limit int `json:"limit,omitempty"` } // ConvertGiftToStarsParams https://core.telegram.org/bots/api#convertgifttostars @@ -1239,7 +1251,7 @@ type UpgradeGiftParams struct { type TransferGiftParams struct { BusinessConnectionID string `json:"business_connection_id"` OwnedGiftID string `json:"owned_gift_id"` - NewOwnerChatID int `json:"new_owner_chat_id"` + NewOwnerChatID int64 `json:"new_owner_chat_id"` StarCount int `json:"star_count"` } @@ -1336,3 +1348,70 @@ type SetChatMemberTagParams struct { UserID int64 `json:"user_id" rules:"required"` Tag string `json:"tag,omitempty"` } + +type GetManagedBotTokenParams struct { + UserID int64 `json:"user_id"` +} + +type ReplaceManagedBotTokenParams struct { + UserID int64 `json:"user_id"` +} + +type SavePreparedKeyboardButtonParams struct { + UserID int64 `json:"user_id"` + Button models.KeyboardButton `json:"button"` +} + +type AnswerGuestQueryParams struct { + GuestQueryID string `json:"guest_query_id"` + Result models.InlineQueryResult `json:"result"` +} + +type DeleteAllMessageReactionsParams struct { + ChatID any `json:"chat_id"` + UserID int64 `json:"user_id,omitempty"` + ActorChatID int64 `json:"actor_chat_id,omitempty"` +} + +type DeleteMessageReactionParams struct { + ChatID any `json:"chat_id"` + MessageID int `json:"message_id"` + UserID int64 `json:"user_id,omitempty"` + ActorChatID int64 `json:"actor_chat_id,omitempty"` +} + +type SendLivePhotoParams struct { + BusinessConnectionID string `json:"business_connection_id,omitempty"` + ChatID any `json:"chat_id"` + MessageThreadID int `json:"message_thread_id,omitempty"` + DirectMessagesTopicID int `json:"direct_messages_topic_id,omitempty"` + LivePhoto models.InputFile `json:"live_photo"` + Photo models.InputFile `json:"photo"` + Caption string `json:"caption,omitempty"` + ParseMode models.ParseMode `json:"parse_mode,omitempty"` + CaptionEntities []models.MessageEntity `json:"caption_entities,omitempty"` + ShowCaptionAboveMedia bool `json:"show_caption_above_media,omitempty"` + HasSpoiler bool `json:"has_spoiler,omitempty"` + DisableNotification bool `json:"disable_notification,omitempty"` + ProtectContent bool `json:"protect_content,omitempty"` + AllowPaidBroadcast bool `json:"allow_paid_broadcast,omitempty"` + MessageEffectID string `json:"message_effect_id,omitempty"` + SuggestedPostParameters *models.SuggestedPostParameters `json:"suggested_post_parameters,omitempty"` + ReplyParameters *models.ReplyParameters `json:"reply_parameters,omitempty"` + ReplyMarkup models.ReplyMarkup `json:"reply_markup,omitempty"` +} + +type GetManagedBotAccessSettingsParams struct { + UserID int64 `json:"user_id"` +} + +type SetManagedBotAccessSettingsParams struct { + UserID int64 `json:"user_id"` + IsAccessRestricted bool `json:"is_access_restricted"` + AddedUserIDs []int64 `json:"added_user_ids,omitempty"` +} + +type GetUserPersonalChatMessagesParams struct { + UserID int64 `json:"user_id"` + Limit int `json:"limit"` +} diff --git a/vendor/github.com/go-telegram/bot/models/chat.go b/vendor/github.com/go-telegram/bot/models/chat.go index da96b53..c19115a 100644 --- a/vendor/github.com/go-telegram/bot/models/chat.go +++ b/vendor/github.com/go-telegram/bot/models/chat.go @@ -54,7 +54,7 @@ type ChatAdministratorRights struct { // ChatPermissions https://core.telegram.org/bots/api#chatpermissions type ChatPermissions struct { - CanSendMessages bool `json:"can_send_messages,omitempty"` + CanSendMessages bool `json:"can_send_messages"` CanSendAudios bool `json:"can_send_audios"` CanSendDocuments bool `json:"can_send_documents"` CanSendPhotos bool `json:"can_send_photos"` @@ -69,6 +69,7 @@ type ChatPermissions struct { CanPinMessages bool `json:"can_pin_messages,omitempty"` CanManageTopics bool `json:"can_manage_topics,omitempty"` CanEditTag bool `json:"can_edit_tag,omitempty"` + CanReactToMessages bool `json:"can_react_to_messages,omitempty"` } // ChatLocation https://core.telegram.org/bots/api#chatlocation diff --git a/vendor/github.com/go-telegram/bot/models/chat_member.go b/vendor/github.com/go-telegram/bot/models/chat_member.go index 0eac6f0..14753d6 100644 --- a/vendor/github.com/go-telegram/bot/models/chat_member.go +++ b/vendor/github.com/go-telegram/bot/models/chat_member.go @@ -164,6 +164,7 @@ type ChatMemberRestricted struct { CanPinMessages bool `json:"can_pin_messages"` CanManageTopics bool `json:"can_manage_topics,omitempty"` CanEditTag bool `json:"can_edit_tag,omitempty"` + CanReactToMessages bool `json:"can_react_to_messages,omitempty"` UntilDate int `json:"until_date"` Tag string `json:"tag,omitempty"` } diff --git a/vendor/github.com/go-telegram/bot/models/gift.go b/vendor/github.com/go-telegram/bot/models/gift.go index 1cd4358..72fc3e6 100644 --- a/vendor/github.com/go-telegram/bot/models/gift.go +++ b/vendor/github.com/go-telegram/bot/models/gift.go @@ -127,12 +127,12 @@ type OwnedGifts struct { // UniqueGiftColors https://core.telegram.org/bots/api#uniquegiftcolors type UniqueGiftColors struct { - ModelCustomEmojiID string `json:"model_custom_emoji_id"` - SymbolCustomEmojiID string `json:"symbol_custom_emoji_id"` - LightThemeMainColor int `json:"light_theme_main_color"` - LightThemeOtherColors []int `json:"light_theme_other_colors"` - DarkThemeMainColor int `json:"dark_theme_main_color"` - DarkThemeOtherColors []int `json:"dark_theme_other_colors"` + ModelCustomEmojiID string `json:"model_custom_emoji_id"` + SymbolCustomEmojiID string `json:"symbol_custom_emoji_id"` + LightThemeMainColor int `json:"light_theme_main_color"` + LightThemeOtherColors []int `json:"light_theme_other_colors"` + DarkThemeMainColor int `json:"dark_theme_main_color"` + DarkThemeOtherColors []int `json:"dark_theme_other_colors"` } // UniqueGift https://core.telegram.org/bots/api#uniquegift diff --git a/vendor/github.com/go-telegram/bot/models/guest_live.go b/vendor/github.com/go-telegram/bot/models/guest_live.go new file mode 100644 index 0000000..f911fc8 --- /dev/null +++ b/vendor/github.com/go-telegram/bot/models/guest_live.go @@ -0,0 +1,37 @@ +package models + +// SentGuestMessage https://core.telegram.org/bots/api#sentguestmessage +type SentGuestMessage struct { + InlineMessageID string `json:"inline_message_id"` +} + +// LivePhoto https://core.telegram.org/bots/api#livephoto +type LivePhoto struct { + Photo []PhotoSize `json:"photo,omitempty"` + FileID string `json:"file_id"` + FileUniqueID string `json:"file_unique_id"` + Width int `json:"width"` + Height int `json:"height"` + Duration int `json:"duration"` + MimeType string `json:"mime_type,omitempty"` + FileSize int `json:"file_size,omitempty"` +} + +// PaidMediaLivePhoto https://core.telegram.org/bots/api#paidmedialivephoto +type PaidMediaLivePhoto struct { + Type string `json:"type"` + LivePhoto LivePhoto `json:"live_photo"` +} + +// InputPaidMediaLivePhoto https://core.telegram.org/bots/api#inputpaidmedialivephoto +type InputPaidMediaLivePhoto struct { + Type string `json:"type"` + Media string `json:"media"` + Photo string `json:"photo"` +} + +// BotAccessSettings https://core.telegram.org/bots/api#botaccesssettings +type BotAccessSettings struct { + IsAccessRestricted bool `json:"is_access_restricted"` + AddedUsers []User `json:"added_users,omitempty"` +} diff --git a/vendor/github.com/go-telegram/bot/models/input_media.go b/vendor/github.com/go-telegram/bot/models/input_media.go index 0f50e38..539bca6 100644 --- a/vendor/github.com/go-telegram/bot/models/input_media.go +++ b/vendor/github.com/go-telegram/bot/models/input_media.go @@ -188,3 +188,122 @@ func (m InputMediaDocument) MarshalInputMedia() ([]byte, error) { } func (InputMediaDocument) inputMediaTag() {} + +// InputMediaLivePhoto https://core.telegram.org/bots/api#inputmedialivephoto +type InputMediaLivePhoto struct { + Media string `json:"media"` + Photo string `json:"photo"` + Caption string `json:"caption,omitempty"` + ParseMode ParseMode `json:"parse_mode,omitempty"` + CaptionEntities []MessageEntity `json:"caption_entities,omitempty"` + ShowCaptionAboveMedia bool `json:"show_caption_above_media,omitempty"` + HasSpoiler bool `json:"has_spoiler,omitempty"` + MediaAttachment io.Reader `json:"-"` + PhotoAttachment io.Reader `json:"-"` +} + +func (m *InputMediaLivePhoto) Attachment() io.Reader { + return m.MediaAttachment +} + +func (m *InputMediaLivePhoto) GetMedia() string { + return m.Media +} + +func (m InputMediaLivePhoto) MarshalInputMedia() ([]byte, error) { + return json.Marshal(&struct { + Type string `json:"type"` + InputMediaLivePhoto + }{ + Type: "live_photo", + InputMediaLivePhoto: m, + }) +} + +func (InputMediaLivePhoto) inputMediaTag() {} + +// InputMediaLocation https://core.telegram.org/bots/api#inputmedialocation +type InputMediaLocation struct { + Latitude float64 `json:"latitude"` + Longitude float64 `json:"longitude"` + HorizontalAccuracy float64 `json:"horizontal_accuracy,omitempty"` +} + +func (m *InputMediaLocation) Attachment() io.Reader { + return nil +} + +func (m *InputMediaLocation) GetMedia() string { + return "" +} + +func (m *InputMediaLocation) MarshalInputMedia() ([]byte, error) { + return json.Marshal(&struct { + Type string `json:"type"` + *InputMediaLocation + }{ + Type: "location", + InputMediaLocation: m, + }) +} + +func (InputMediaLocation) inputMediaTag() {} + +// InputMediaSticker https://core.telegram.org/bots/api#inputmediasticker +type InputMediaSticker struct { + Media string `json:"media"` + Emoji string `json:"emoji,omitempty"` + MediaAttachment io.Reader `json:"-"` +} + +func (m *InputMediaSticker) Attachment() io.Reader { + return m.MediaAttachment +} + +func (m *InputMediaSticker) GetMedia() string { + return m.Media +} + +func (m *InputMediaSticker) MarshalInputMedia() ([]byte, error) { + return json.Marshal(&struct { + Type string `json:"type"` + *InputMediaSticker + }{ + Type: "sticker", + InputMediaSticker: m, + }) +} + +func (InputMediaSticker) inputMediaTag() {} + +// InputMediaVenue https://core.telegram.org/bots/api#inputmediavenue +type InputMediaVenue struct { + Latitude float64 `json:"latitude"` + Longitude float64 `json:"longitude"` + Title string `json:"title"` + Address string `json:"address"` + FoursquareID string `json:"foursquare_id,omitempty"` + FoursquareType string `json:"foursquare_type,omitempty"` + GooglePlaceID string `json:"google_place_id,omitempty"` + GooglePlaceType string `json:"google_place_type,omitempty"` +} + +func (m *InputMediaVenue) Attachment() io.Reader { + return nil +} + +func (m *InputMediaVenue) GetMedia() string { + return "" +} + +func (m *InputMediaVenue) MarshalInputMedia() ([]byte, error) { + return json.Marshal(&struct { + Type string `json:"type"` + *InputMediaVenue + }{ + Type: "venue", + InputMediaVenue: m, + }) +} + +func (InputMediaVenue) inputMediaTag() {} diff --git a/vendor/github.com/go-telegram/bot/models/managed_bot.go b/vendor/github.com/go-telegram/bot/models/managed_bot.go new file mode 100644 index 0000000..b076402 --- /dev/null +++ b/vendor/github.com/go-telegram/bot/models/managed_bot.go @@ -0,0 +1,24 @@ +package models + +// KeyboardButtonRequestManagedBot https://core.telegram.org/bots/api#keyboardbuttonrequestmanagedbot +type KeyboardButtonRequestManagedBot struct { + RequestID int32 `json:"request_id"` + SuggestedName string `json:"suggested_name,omitempty"` + SuggestedUsername string `json:"suggested_username,omitempty"` +} + +// ManagedBotCreated https://core.telegram.org/bots/api#managedbotcreated +type ManagedBotCreated struct { + Bot *User `json:"bot,omitempty"` +} + +// ManagedBotUpdated https://core.telegram.org/bots/api#managedbotupdated +type ManagedBotUpdated struct { + User *User `json:"user,omitempty"` + Bot *User `json:"bot,omitempty"` +} + +// PreparedKeyboardButton https://core.telegram.org/bots/api#preparedkeyboardbutton +type PreparedKeyboardButton struct { + ID string `json:"id"` +} diff --git a/vendor/github.com/go-telegram/bot/models/message.go b/vendor/github.com/go-telegram/bot/models/message.go index 530a102..e7e172c 100644 --- a/vendor/github.com/go-telegram/bot/models/message.go +++ b/vendor/github.com/go-telegram/bot/models/message.go @@ -180,11 +180,19 @@ type Message struct { SuggestedPostDeclined *SuggestedPostDeclined `json:"suggested_post_declined,omitempty"` SuggestedPostPaid *SuggestedPostPaid `json:"suggested_post_paid,omitempty"` SuggestedPostRefunded *SuggestedPostRefunded `json:"suggested_post_refunded,omitempty"` - VoiceChatScheduled *VoiceChatScheduled `json:"voice_chat_scheduled,omitempty"` - VoiceChatStarted *VoiceChatStarted `json:"voice_chat_started,omitempty"` - VoiceChatEnded *VoiceChatEnded `json:"voice_chat_ended,omitempty"` - VoiceChatParticipantsInvited *VoiceChatParticipantsInvited `json:"voice_chat_participants_invited,omitempty"` + VideoChatScheduled *VideoChatScheduled `json:"video_chat_scheduled,omitempty"` + VideoChatStarted *VideoChatStarted `json:"video_chat_started,omitempty"` + VideoChatEnded *VideoChatEnded `json:"video_chat_ended,omitempty"` + VideoChatParticipantsInvited *VideoChatParticipantsInvited `json:"video_chat_participants_invited,omitempty"` WebAppData *WebAppData `json:"web_app_data,omitempty"` + ManagedBotCreated *ManagedBotCreated `json:"managed_bot_created,omitempty"` + PollOptionAdded *PollOptionAdded `json:"poll_option_added,omitempty"` + PollOptionDeleted *PollOptionDeleted `json:"poll_option_deleted,omitempty"` + GuestBotCallerUser *User `json:"guest_bot_caller_user,omitempty"` + GuestBotCallerChat *Chat `json:"guest_bot_caller_chat,omitempty"` + GuestQueryID string `json:"guest_query_id,omitempty"` + ReplyToPollOptionID string `json:"reply_to_poll_option_id,omitempty"` + LivePhoto *LivePhoto `json:"live_photo,omitempty"` ReplyMarkup *InlineKeyboardMarkup `json:"reply_markup,omitempty"` } diff --git a/vendor/github.com/go-telegram/bot/models/message_entity.go b/vendor/github.com/go-telegram/bot/models/message_entity.go index 34f436b..5008e4e 100644 --- a/vendor/github.com/go-telegram/bot/models/message_entity.go +++ b/vendor/github.com/go-telegram/bot/models/message_entity.go @@ -27,12 +27,12 @@ const ( // MessageEntity https://core.telegram.org/bots/api#messageentity type MessageEntity struct { - Type MessageEntityType `json:"type"` - Offset int `json:"offset"` - Length int `json:"length"` - URL string `json:"url,omitempty"` - User *User `json:"user,omitempty"` - Language string `json:"language,omitempty"` + Type MessageEntityType `json:"type"` + Offset int `json:"offset"` + Length int `json:"length"` + URL string `json:"url,omitempty"` + User *User `json:"user,omitempty"` + Language string `json:"language,omitempty"` CustomEmojiID string `json:"custom_emoji_id,omitempty"` UnixTime int `json:"unix_time,omitempty"` DateTimeFormat string `json:"date_time_format,omitempty"` diff --git a/vendor/github.com/go-telegram/bot/models/poll.go b/vendor/github.com/go-telegram/bot/models/poll.go index b1c9104..c88bbc8 100644 --- a/vendor/github.com/go-telegram/bot/models/poll.go +++ b/vendor/github.com/go-telegram/bot/models/poll.go @@ -1,11 +1,14 @@ package models +import "encoding/json" + // PollAnswer https://core.telegram.org/bots/api#pollanswer type PollAnswer struct { - PollID string `json:"poll_id"` - VoterChat *Chat `json:"voter_chat,omitempty"` - User *User `json:"user"` - OptionIDs []int `json:"option_ids,omitempty"` + PollID string `json:"poll_id"` + VoterChat *Chat `json:"voter_chat,omitempty"` + User *User `json:"user,omitempty"` + OptionIDs []int `json:"option_ids,omitempty"` + OptionPersistentIDs []string `json:"option_persistent_ids,omitempty"` } // InputPollOption https://core.telegram.org/bots/api#inputpolloption @@ -13,6 +16,30 @@ type InputPollOption struct { Text string `json:"text"` TextParseMode ParseMode `json:"text_parse_mode,omitempty"` TextEntities []MessageEntity `json:"text_entities,omitempty"` + Media InputMedia `json:"media,omitempty"` +} + +func (o InputPollOption) MarshalJSON() ([]byte, error) { + type base struct { + Text string `json:"text"` + TextParseMode ParseMode `json:"text_parse_mode,omitempty"` + TextEntities []MessageEntity `json:"text_entities,omitempty"` + } + b := base{Text: o.Text, TextParseMode: o.TextParseMode, TextEntities: o.TextEntities} + if o.Media == nil { + return json.Marshal(b) + } + raw, err := o.Media.MarshalInputMedia() + if err != nil { + return nil, err + } + return json.Marshal(struct { + base + Media json.RawMessage `json:"media"` + }{ + base: b, + Media: raw, + }) } // PollOption https://core.telegram.org/bots/api#polloption @@ -20,6 +47,24 @@ type PollOption struct { Text string `json:"text"` TextEntities []MessageEntity `json:"text_entities,omitempty"` VoterCount int `json:"voter_count"` + PersistentID string `json:"persistent_id,omitempty"` + Media *PollMedia `json:"media,omitempty"` + AddedByUser *User `json:"added_by_user,omitempty"` + AddedByChat *Chat `json:"added_by_chat,omitempty"` + AdditionDate int `json:"addition_date,omitempty"` +} + +// PollMedia https://core.telegram.org/bots/api#pollmedia +type PollMedia struct { + Animation *Animation `json:"animation,omitempty"` + Audio *Audio `json:"audio,omitempty"` + Document *Document `json:"document,omitempty"` + LivePhoto *LivePhoto `json:"live_photo,omitempty"` + Location *Location `json:"location,omitempty"` + Photo []PhotoSize `json:"photo,omitempty"` + Sticker *Sticker `json:"sticker,omitempty"` + Venue *Venue `json:"venue,omitempty"` + Video *Video `json:"video,omitempty"` } // Poll https://core.telegram.org/bots/api#poll @@ -33,9 +78,32 @@ type Poll struct { IsAnonymous bool `json:"is_anonymous"` Type string `json:"type"` AllowsMultipleAnswers bool `json:"allows_multiple_answers"` - CorrectOptionID int `json:"correct_option_id,omitempty"` + CorrectOptionIDs []int `json:"correct_option_ids,omitempty"` Explanation string `json:"explanation,omitempty"` ExplanationEntities []MessageEntity `json:"explanation_entities,omitempty"` + Description string `json:"description,omitempty"` + DescriptionEntities []MessageEntity `json:"description_entities,omitempty"` + Media *PollMedia `json:"media,omitempty"` + ExplanationMedia *PollMedia `json:"explanation_media,omitempty"` + MembersOnly bool `json:"members_only,omitempty"` + CountryCodes []string `json:"country_codes,omitempty"` + AllowsRevoting bool `json:"allows_revoting,omitempty"` OpenPeriod int `json:"open_period,omitempty"` CloseDate int `json:"close_date,omitempty"` } + +// PollOptionAdded https://core.telegram.org/bots/api#polloptionadded +type PollOptionAdded struct { + PollMessage *MaybeInaccessibleMessage `json:"poll_message,omitempty"` + OptionPersistentID string `json:"option_persistent_id"` + OptionText string `json:"option_text"` + OptionTextEntities []MessageEntity `json:"option_text_entities,omitempty"` +} + +// PollOptionDeleted https://core.telegram.org/bots/api#polloptiondeleted +type PollOptionDeleted struct { + PollMessage *MaybeInaccessibleMessage `json:"poll_message,omitempty"` + OptionPersistentID string `json:"option_persistent_id"` + OptionText string `json:"option_text"` + OptionTextEntities []MessageEntity `json:"option_text_entities,omitempty"` +} diff --git a/vendor/github.com/go-telegram/bot/models/reply.go b/vendor/github.com/go-telegram/bot/models/reply.go index 5eb14bb..22f5157 100644 --- a/vendor/github.com/go-telegram/bot/models/reply.go +++ b/vendor/github.com/go-telegram/bot/models/reply.go @@ -40,6 +40,7 @@ type ExternalReplyInfo struct { Location *Location `json:"location,omitempty"` Poll *Poll `json:"poll,omitempty"` Venue *Venue `json:"venue,omitempty"` + LivePhoto *LivePhoto `json:"live_photo,omitempty"` } // ReplyParameters https://core.telegram.org/bots/api#replyparameters @@ -52,6 +53,7 @@ type ReplyParameters struct { QuoteEntities []MessageEntity `json:"quote_entities,omitempty"` QuotePosition int `json:"quote_position,omitempty"` ChecklistTaskID int `json:"checklist_task_id,omitempty"` + PollOptionID string `json:"poll_option_id,omitempty"` } // MessageOriginType https://core.telegram.org/bots/api#messageorigin diff --git a/vendor/github.com/go-telegram/bot/models/reply_markup.go b/vendor/github.com/go-telegram/bot/models/reply_markup.go index 39353ae..0b93135 100644 --- a/vendor/github.com/go-telegram/bot/models/reply_markup.go +++ b/vendor/github.com/go-telegram/bot/models/reply_markup.go @@ -58,16 +58,17 @@ type ReplyKeyboardMarkup struct { // KeyboardButton https://core.telegram.org/bots/api#keyboardbutton type KeyboardButton struct { - Text string `json:"text"` - IconCustomEmojiID string `json:"icon_custom_emoji_id,omitempty"` - Style string `json:"style,omitempty"` - RequestUser *KeyboardButtonRequestUser `json:"request_user,omitempty"` - RequestUsers *KeyboardButtonRequestUsers `json:"request_users,omitempty"` - RequestChat *KeyboardButtonRequestChat `json:"request_chat,omitempty"` - RequestContact bool `json:"request_contact,omitempty"` - RequestLocation bool `json:"request_location,omitempty"` - RequestPoll *KeyboardButtonPollType `json:"request_poll,omitempty"` - WebApp *WebAppInfo `json:"web_app,omitempty"` + Text string `json:"text"` + IconCustomEmojiID string `json:"icon_custom_emoji_id,omitempty"` + Style string `json:"style,omitempty"` + RequestUser *KeyboardButtonRequestUser `json:"request_user,omitempty"` + RequestUsers *KeyboardButtonRequestUsers `json:"request_users,omitempty"` + RequestChat *KeyboardButtonRequestChat `json:"request_chat,omitempty"` + RequestContact bool `json:"request_contact,omitempty"` + RequestLocation bool `json:"request_location,omitempty"` + RequestPoll *KeyboardButtonPollType `json:"request_poll,omitempty"` + RequestManagedBot *KeyboardButtonRequestManagedBot `json:"request_managed_bot,omitempty"` + WebApp *WebAppInfo `json:"web_app,omitempty"` } // KeyboardButtonRequestUser https://core.telegram.org/bots/api#keyboardbuttonrequestuser diff --git a/vendor/github.com/go-telegram/bot/models/update.go b/vendor/github.com/go-telegram/bot/models/update.go index d98b65b..925c9cc 100644 --- a/vendor/github.com/go-telegram/bot/models/update.go +++ b/vendor/github.com/go-telegram/bot/models/update.go @@ -21,6 +21,8 @@ type Update struct { PurchasedPaidMedia *PaidMediaPurchased `json:"purchased_paid_media,omitempty"` Poll *Poll `json:"poll,omitempty"` PollAnswer *PollAnswer `json:"poll_answer,omitempty"` + ManagedBot *ManagedBotUpdated `json:"managed_bot,omitempty"` + GuestMessage *Message `json:"guest_message,omitempty"` MyChatMember *ChatMemberUpdated `json:"my_chat_member,omitempty"` ChatMember *ChatMemberUpdated `json:"chat_member,omitempty"` ChatJoinRequest *ChatJoinRequest `json:"chat_join_request,omitempty"` @@ -53,4 +55,6 @@ const ( AllowedUpdateChatJoinRequest string = "chat_join_request" AllowedUpdateChatBoost string = "chat_boost" AllowedUpdateRemovedChatBoost string = "removed_chat_boost" + AllowedUpdateManagedBot string = "managed_bot" + AllowedUpdateGuestMessage string = "guest_message" ) diff --git a/vendor/github.com/go-telegram/bot/models/user.go b/vendor/github.com/go-telegram/bot/models/user.go index 6274e39..617e14d 100644 --- a/vendor/github.com/go-telegram/bot/models/user.go +++ b/vendor/github.com/go-telegram/bot/models/user.go @@ -8,20 +8,22 @@ type UserProfilePhotos struct { // User https://core.telegram.org/bots/api#user type User struct { - ID int64 `json:"id"` - IsBot bool `json:"is_bot"` - FirstName string `json:"first_name,omitempty"` - LastName string `json:"last_name,omitempty"` - Username string `json:"username,omitempty"` - LanguageCode string `json:"language_code,omitempty"` - IsPremium bool `json:"is_premium,omitempty"` - AddedToAttachmentMenu bool `json:"added_to_attachment_menu,omitempty"` - CanJoinGroups bool `json:"can_join_groups,omitempty"` - CanReadAllGroupMessages bool `json:"can_read_all_group_messages,omitempty"` - SupportInlineQueries bool `json:"support_inline_queries,omitempty"` - CanConnectToBusiness bool `json:"can_connect_to_business,omitempty"` - HasTopicsEnabled bool `json:"has_topics_enabled,omitempty"` - AllowsUsersToCreateTopics bool `json:"allows_users_to_create_topics,omitempty"` + ID int64 `json:"id"` + IsBot bool `json:"is_bot"` + FirstName string `json:"first_name,omitempty"` + LastName string `json:"last_name,omitempty"` + Username string `json:"username,omitempty"` + LanguageCode string `json:"language_code,omitempty"` + IsPremium bool `json:"is_premium,omitempty"` + AddedToAttachmentMenu bool `json:"added_to_attachment_menu,omitempty"` + CanJoinGroups bool `json:"can_join_groups,omitempty"` + CanReadAllGroupMessages bool `json:"can_read_all_group_messages,omitempty"` + SupportInlineQueries bool `json:"support_inline_queries,omitempty"` + CanConnectToBusiness bool `json:"can_connect_to_business,omitempty"` + HasTopicsEnabled bool `json:"has_topics_enabled,omitempty"` + AllowsUsersToCreateTopics bool `json:"allows_users_to_create_topics,omitempty"` + CanManageBots bool `json:"can_manage_bots,omitempty"` + SupportsGuestQueries bool `json:"supports_guest_queries,omitempty"` } // UserProfileAudios https://core.telegram.org/bots/api#userprofileaudios diff --git a/vendor/github.com/go-telegram/bot/models/voice_chat.go b/vendor/github.com/go-telegram/bot/models/voice_chat.go deleted file mode 100644 index 76192d7..0000000 --- a/vendor/github.com/go-telegram/bot/models/voice_chat.go +++ /dev/null @@ -1,21 +0,0 @@ -package models - -// VoiceChatScheduled https://core.telegram.org/bots/api#videochatscheduled -type VoiceChatScheduled struct { - StartDate int `json:"start_date"` -} - -// VoiceChatStarted https://core.telegram.org/bots/api#videochatstarted -type VoiceChatStarted struct { - Duration int `json:"duration"` -} - -// VoiceChatEnded https://core.telegram.org/bots/api#videochatended -type VoiceChatEnded struct { - Duration int `json:"duration"` -} - -// VoiceChatParticipantsInvited https://core.telegram.org/bots/api#videochatparticipantsinvited -type VoiceChatParticipantsInvited struct { - Users []User `json:"users"` -} diff --git a/vendor/modules.txt b/vendor/modules.txt index ca80d42..795ff13 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -1,7 +1,7 @@ # github.com/davecgh/go-spew v1.1.1 ## explicit github.com/davecgh/go-spew/spew -# github.com/go-telegram/bot v1.20.0 +# github.com/go-telegram/bot v1.21.0 ## explicit; go 1.18 github.com/go-telegram/bot github.com/go-telegram/bot/models