Telegram.Bot v17.0.0-alpha.1 Release Notes

Release Date: 2021-06-13 // almost 3 years ago
  • Bot API 5.3 (June 25, 2021)

    โž• Added

    • Enum InputMediaType
    • Type BanCommandScope
    • 0๏ธโƒฃ Type BanCommandScopeDefault
    • Type BanCommandScopeAllPrivateChats
    • Type BanCommandScopeAllGroupChats
    • Type BanCommandScopeAllChatAdministrators
    • Type BanCommandScopeChat
    • Type BanCommandScopeChatAdministrators
    • Type BanCommandScopeChatMember
    • Enum BanCommandScopeType
    • Type ChatMemberOwner
    • Type ChatMemberAdministrator
    • Type ChatMemberMember
    • Type ChatMemberRestricted
    • Type ChatMemberLeft
    • Type ChatMemberBanned
    • Request BanChatMemberRequest
    • Request BanChatMemberRequest
    • Request DeleteMyCommandsRequest
    • Request GetChatMemberCountRequest
    • Method ITelegramBotClient.DeleteMyCommandsAsync
    • Method ITelegramBotClient.BanChatMemberAsync
    • Method ITelegramBotClient.GetChatMemberCountAsync
    • Property BotCommandScope GetMyCommandsRequest.Scope { get; set; }
    • Property string GetMyCommandsRequest.LanguageCode { get; set; }
    • Property BotCommandScope SetMyCommandsRequest.Scope { get; set; }
    • Property string SetMyCommandsRequest.LanguageCode { get; set; }
    • Property IRequest<TResponse>.IsWebhookResponse { get; set; }
    • Protected constructor InputMediaBase that accepts InputMedia
    • Protected constructor InputTelegramFile that accepts FileType
    • Property string ForceReplyMarkup.InputFieldPlaceholder { get; set; }
    • Property string ReplyKeyboardMarkup.InputFieldPlaceholder { get; set; }
    • Enum EncryptedPassportElementType
    • Interface IChatTargetable
    • Interface IUserTargetable

    ๐Ÿ”„ Changed

    • Type InlineQueryResultBase renamed to InlineQueryResult
    • Type ChatMember is made abstract
    • Property ChatMember.Status is made abstract
    • 0๏ธโƒฃ Every use of enum ParseMode is made nullable to represent default text mode without any markup
    • Type KickChatMemberRequest is marked as obsolete
    • Type GetChatMembersCountRequest is marked as obsolete
    • Method ITelegramBotClient.KickChatMemberAsync is marked as obsolete
    • Method ITelegramBotClient.GetChatMembersCountAsync is marked as obsolete
    • All underlying enum values changed to start from 1 instead of 0. 0 value are reserved for unknown enum values.
    • ๐Ÿšš Type ChatMember is made abstract and it's properties are moved into separate inheriting classes
    • ๐Ÿ”„ Changed parameters in ITelegramBotClient.GetMyCommandsAsync: added parameters BotCommandScope scope and string language
    • ๐Ÿ”„ Changed parameters in ITelegramBotClient.SetMyCommandsAsync: added parameters BotCommandScope scope and string language
    • Type of property IInputMedia.Type changed from string to InputMediaType
    • Property InputFileStream.FileType is no longer virtual
    • Constructor of type InputFileStream that accepts both Stream content and string fileName: filename parameter is made optional
    • Constructor of type InputOnlineFile that accepts both Stream content and string fileName: filename parameter is made optional
    • Constructor of type InputTelegramFile that accepts both Stream content and string fileName: filename parameter is made optional
    • Property InputMediaBase.Type is made abstract
    • Protected setter InputTelegramFile.FileId is made private protected
    • Type of property EncryptedPassportElement.Type changed from string to EncryptedPassportElementType
    • All optional types are made nullable be it value or reference types

    โœ‚ Removed

    • Public setter ChatMember.Status
    • 0๏ธโƒฃ Enum member ParseMode.Default
    • Enum members ChatAction.RecordAudio and ChatAction.UploadAudio
    • Protected setter from property InputFileStream.Content
    • Constructor of type InputFileStream that accepts only Stream
    • Constructor of type InputOnlineFile that accepts only Stream
    • Constructor of type InputTelegramFile that accepts only Stream
    • Property setter InputMediaBase.Media
    • Protected setter InputOnlineFile.Url
    • All obsolete types, methods and properties related to polling events
    • Following interfaces: ICaptionEntities, IEntities, IFormattableEntities, IInlineMessage, IInlineReplyMarkupMessage, INotifiableMessage, IReplyMarkupMessage, IReplyMessage, IThumbMediaMessage, ICaptionInlineQueryResult, ILocationInlineQueryResult, IThumbnailInlineQueryResult, IThumbnailUrlInlineQueryResult