diff --git a/README.md b/README.md index 60b9735..492941c 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ ![.NET Core](https://github.com/Dolfik1/Funogram/workflows/.NET/badge.svg) [![NuGet](https://img.shields.io/nuget/v/Funogram.svg)](https://www.nuget.org/packages/Funogram/) [![NuGet](https://img.shields.io/nuget/v/Funogram.Telegram.svg)](https://www.nuget.org/packages/Funogram.Telegram/) -[![NuGet](https://img.shields.io/badge/Bot%20API-7.10-blue?logo=telegram)](https://www.nuget.org/packages/Funogram.Telegram/) +[![NuGet](https://img.shields.io/badge/Bot%20API-8.2-blue?logo=telegram)](https://www.nuget.org/packages/Funogram.Telegram/) Funogram Logo diff --git a/src/Funogram.Generator/Methods/MethodsParser.fs b/src/Funogram.Generator/Methods/MethodsParser.fs index 06dd430..6c1d621 100644 --- a/src/Funogram.Generator/Methods/MethodsParser.fs +++ b/src/Funogram.Generator/Methods/MethodsParser.fs @@ -44,6 +44,8 @@ let loadRemapData remapPath config = let private returnTypeRegexes = [| + // Returns the list of gifts that can be sent by the bot to users. Requires no parameters. Returns a Gifts object + // invite links Regex("Returns the new invite link as a ([A|a]rray of \w+|\w+)\s") Regex("Returns the new invite link as ([A|a]rray of \w+|\w+)\s") @@ -59,10 +61,10 @@ let private returnTypeRegexes = Regex("([A|a]rray of \w+|\w+) is returned, otherwise ([A|a]rray of \w+|\w+)") + Regex("[R|r]eturns a ([A|a]rray of \w+|\w+)\s") Regex("[R|r]eturns the uploaded (\w+)\s") Regex("[R|r]eturns the ([A|a]rray of \w+|\w+)\s") Regex("[R|r]eturns an ([A|a]rray of \w+|\w+)\s") - Regex("[R|r]eturns a ([A|a]rray of \w+|\w+)\s") Regex("[R|r]eturns ([A|a]rray of \w+|\w+)\s") diff --git a/src/Funogram.Generator/out/methods.json b/src/Funogram.Generator/out/methods.json index 2bc9d06..38f9e09 100644 --- a/src/Funogram.Generator/out/methods.json +++ b/src/Funogram.Generator/out/methods.json @@ -31,7 +31,7 @@ { "OriginalName": "allowed_updates", "ConvertedName": "AllowedUpdates", - "Description": "A JSON-serialized list of the update types you want your bot to receive. For example, specify [\u0022message\u0022, \u0022edited_channel_post\u0022, \u0022callback_query\u0022] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member, message_reaction, and message_reaction_count (default). If not specified, the previous setting will be used.\n\nPlease note that this parameter doesn\u0027t affect updates created before the call to the getUpdates, so unwanted updates may be received for a short period of time.", + "Description": "A JSON-serialized list of the update types you want your bot to receive. For example, specify [\u0022message\u0022, \u0022edited_channel_post\u0022, \u0022callback_query\u0022] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member, message_reaction, and message_reaction_count (default). If not specified, the previous setting will be used.\n\nPlease note that this parameter doesn\u0027t affect updates created before the call to getUpdates, so unwanted updates may be received for a short period of time.", "OriginalFieldType": "Array of String", "ConvertedFieldType": "string[]", "Optional": true @@ -43,7 +43,7 @@ { "OriginalName": "setWebhook", "ConvertedName": "SetWebhook", - "Description": "Use this method to specify a URL and receive incoming updates via an outgoing webhook. Whenever there is an update for the bot, we will send an HTTPS POST request to the specified URL, containing a JSON-serialized Update. In case of an unsuccessful request, we will give up after a reasonable amount of attempts. Returns True on success.", + "Description": "Use this method to specify a URL and receive incoming updates via an outgoing webhook. Whenever there is an update for the bot, we will send an HTTPS POST request to the specified URL, containing a JSON-serialized Update. In case of an unsuccessful request (a request with response HTTP status code different from 2XY), we will repeat the request and give up after a reasonable amount of attempts. Returns True on success.", "Fields": [ { "OriginalName": "url", @@ -231,6 +231,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -458,6 +466,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "reply_parameters", "ConvertedName": "ReplyParameters", @@ -636,6 +652,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -773,6 +797,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -894,6 +926,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -1055,6 +1095,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -1208,6 +1256,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -1321,6 +1377,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -1426,6 +1490,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -1547,6 +1619,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "reply_parameters", "ConvertedName": "ReplyParameters", @@ -1620,6 +1700,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -1733,6 +1821,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -1870,6 +1966,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -1975,6 +2079,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -2160,6 +2272,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -2241,6 +2361,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -2384,6 +2512,39 @@ "OriginalReturnType": "UserProfilePhotos", "ConvertedReturnType": "UserProfilePhotos" }, + { + "OriginalName": "setUserEmojiStatus", + "ConvertedName": "SetUserEmojiStatus", + "Description": "Changes the emoji status for a given user that previously allowed the bot to manage their emoji status via the Mini App method requestEmojiStatusAccess. Returns True on success.", + "Fields": [ + { + "OriginalName": "user_id", + "ConvertedName": "UserId", + "Description": "Unique identifier of the target user", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": false + }, + { + "OriginalName": "emoji_status_custom_emoji_id", + "ConvertedName": "EmojiStatusCustomEmojiId", + "Description": "Custom emoji identifier of the emoji status to set. Pass an empty string to remove the status.", + "OriginalFieldType": "String", + "ConvertedFieldType": "string", + "Optional": true + }, + { + "OriginalName": "emoji_status_expiration_date", + "ConvertedName": "EmojiStatusExpirationDate", + "Description": "Expiration date of the emoji status, if any", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": true + } + ], + "OriginalReturnType": "True", + "ConvertedReturnType": "bool" + }, { "OriginalName": "getFile", "ConvertedName": "GetFile", @@ -4224,7 +4385,7 @@ { "OriginalName": "editMessageMedia", "ConvertedName": "EditMessageMedia", - "Description": "Use this method to edit animation, audio, document, photo, or video messages. If a message is part of a message album, then it can be edited only to an audio for audio albums, only to a document for document albums and to a photo or a video otherwise. When an inline message is edited, a new file can\u0027t be uploaded; use a previously uploaded file via its file_id or specify a URL. On success, if the edited message is not an inline message, the edited Message is returned, otherwise True is returned. Note that business messages that were not sent by the bot and do not contain an inline keyboard can only be edited within 48 hours from the time they were sent.", + "Description": "Use this method to edit animation, audio, document, photo, or video messages, or to add media to text messages. If a message is part of a message album, then it can be edited only to an audio for audio albums, only to a document for document albums and to a photo or a video otherwise. When an inline message is edited, a new file can\u0027t be uploaded; use a previously uploaded file via its file_id or specify a URL. On success, if the edited message is not an inline message, the edited Message is returned, otherwise True is returned. Note that business messages that were not sent by the bot and do not contain an inline keyboard can only be edited within 48 hours from the time they were sent.", "Fields": [ { "OriginalName": "business_connection_id", @@ -4625,6 +4786,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -5017,7 +5186,7 @@ { "OriginalName": "thumbnail", "ConvertedName": "Thumbnail", - "Description": "A .WEBP or .PNG image with the thumbnail, must be up to 128 kilobytes in size and have a width and height of exactly 100px, or a .TGS animation with a thumbnail up to 32 kilobytes in size (see https://core.telegram.org/stickers#animation-requirements for animated sticker technical requirements), or a WEBM video with the thumbnail up to 32 kilobytes in size; see https://core.telegram.org/stickers#video-requirements for video sticker technical requirements. Pass a file_id as a String to send a file that already exists on the Telegram servers, pass an HTTP URL as a String for Telegram to get a file from the Internet, or upload a new one using multipart/form-data. More information on Sending Files \u00BB. Animated and video sticker set thumbnails can\u0027t be uploaded via HTTP URL. If omitted, then the thumbnail is dropped and the first sticker is used as the thumbnail.", + "Description": "A .WEBP or .PNG image with the thumbnail, must be up to 128 kilobytes in size and have a width and height of exactly 100px, or a .TGS animation with a thumbnail up to 32 kilobytes in size (see https://core.telegram.org/stickers#animation-requirements for animated sticker technical requirements), or a .WEBM video with the thumbnail up to 32 kilobytes in size; see https://core.telegram.org/stickers#video-requirements for video sticker technical requirements. Pass a file_id as a String to send a file that already exists on the Telegram servers, pass an HTTP URL as a String for Telegram to get a file from the Internet, or upload a new one using multipart/form-data. More information on Sending Files \u00BB. Animated and video sticker set thumbnails can\u0027t be uploaded via HTTP URL. If omitted, then the thumbnail is dropped and the first sticker is used as the thumbnail.", "OriginalFieldType": "InputFile or String", "ConvertedFieldType": "InputFile", "Optional": true @@ -5025,7 +5194,7 @@ { "OriginalName": "format", "ConvertedName": "Format", - "Description": "Format of the thumbnail, must be one of \u201Cstatic\u201D for a .WEBP or .PNG image, \u201Canimated\u201D for a .TGS animation, or \u201Cvideo\u201D for a WEBM video", + "Description": "Format of the thumbnail, must be one of \u201Cstatic\u201D for a .WEBP or .PNG image, \u201Canimated\u201D for a .TGS animation, or \u201Cvideo\u201D for a .WEBM video", "OriginalFieldType": "String", "ConvertedFieldType": "string", "Optional": false @@ -5076,6 +5245,155 @@ "OriginalReturnType": "True", "ConvertedReturnType": "bool" }, + { + "OriginalName": "getAvailableGifts", + "ConvertedName": "GetAvailableGifts", + "Description": "Returns the list of gifts that can be sent by the bot to users. Requires no parameters. Returns a Gifts object.", + "Fields": [], + "OriginalReturnType": "Gifts", + "ConvertedReturnType": "Gifts" + }, + { + "OriginalName": "sendGift", + "ConvertedName": "SendGift", + "Description": "Sends a gift to the given user. The gift can\u0027t be converted to Telegram Stars by the user. Returns True on success.", + "Fields": [ + { + "OriginalName": "user_id", + "ConvertedName": "UserId", + "Description": "Unique identifier of the target user that will receive the gift", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": false + }, + { + "OriginalName": "gift_id", + "ConvertedName": "GiftId", + "Description": "Identifier of the gift", + "OriginalFieldType": "String", + "ConvertedFieldType": "string", + "Optional": false + }, + { + "OriginalName": "pay_for_upgrade", + "ConvertedName": "PayForUpgrade", + "Description": "Pass True to pay for the gift upgrade from the bot\u0027s balance, thereby making the upgrade free for the receiver", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, + { + "OriginalName": "text", + "ConvertedName": "Text", + "Description": "Text that will be shown along with the gift; 0-255 characters", + "OriginalFieldType": "String", + "ConvertedFieldType": "string", + "Optional": true + }, + { + "OriginalName": "text_parse_mode", + "ConvertedName": "TextParseMode", + "Description": "Mode for parsing entities in the text. See formatting options for more details. Entities other than \u201Cbold\u201D, \u201Citalic\u201D, \u201Cunderline\u201D, \u201Cstrikethrough\u201D, \u201Cspoiler\u201D, and \u201Ccustom_emoji\u201D are ignored.", + "OriginalFieldType": "String", + "ConvertedFieldType": "string", + "Optional": true + }, + { + "OriginalName": "text_entities", + "ConvertedName": "TextEntities", + "Description": "A JSON-serialized list of special entities that appear in the gift text. It can be specified instead of text_parse_mode. Entities other than \u201Cbold\u201D, \u201Citalic\u201D, \u201Cunderline\u201D, \u201Cstrikethrough\u201D, \u201Cspoiler\u201D, and \u201Ccustom_emoji\u201D are ignored.", + "OriginalFieldType": "Array of MessageEntity", + "ConvertedFieldType": "MessageEntity[]", + "Optional": true + } + ], + "OriginalReturnType": "True", + "ConvertedReturnType": "bool" + }, + { + "OriginalName": "verifyUser", + "ConvertedName": "VerifyUser", + "Description": "Verifies a user on behalf of the organization which is represented by the bot. Returns True on success.", + "Fields": [ + { + "OriginalName": "user_id", + "ConvertedName": "UserId", + "Description": "Unique identifier of the target user", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": false + }, + { + "OriginalName": "custom_description", + "ConvertedName": "CustomDescription", + "Description": "Custom description for the verification; 0-70 characters. Must be empty if the organization isn\u0027t allowed to provide a custom verification description.", + "OriginalFieldType": "String", + "ConvertedFieldType": "string", + "Optional": true + } + ], + "OriginalReturnType": "True", + "ConvertedReturnType": "bool" + }, + { + "OriginalName": "verifyChat", + "ConvertedName": "VerifyChat", + "Description": "Verifies a chat on behalf of the organization which is represented by the bot. Returns True on success.", + "Fields": [ + { + "OriginalName": "chat_id", + "ConvertedName": "ChatId", + "Description": "Unique identifier for the target chat or username of the target channel (in the format @channelusername)", + "OriginalFieldType": "Integer or String", + "ConvertedFieldType": "ChatId", + "Optional": false + }, + { + "OriginalName": "custom_description", + "ConvertedName": "CustomDescription", + "Description": "Custom description for the verification; 0-70 characters. Must be empty if the organization isn\u0027t allowed to provide a custom verification description.", + "OriginalFieldType": "String", + "ConvertedFieldType": "string", + "Optional": true + } + ], + "OriginalReturnType": "True", + "ConvertedReturnType": "bool" + }, + { + "OriginalName": "removeUserVerification", + "ConvertedName": "RemoveUserVerification", + "Description": "Removes verification from a user who is currently verified on behalf of the organization represented by the bot. Returns True on success.", + "Fields": [ + { + "OriginalName": "user_id", + "ConvertedName": "UserId", + "Description": "Unique identifier of the target user", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": false + } + ], + "OriginalReturnType": "True", + "ConvertedReturnType": "bool" + }, + { + "OriginalName": "removeChatVerification", + "ConvertedName": "RemoveChatVerification", + "Description": "Removes verification from a chat that is currently verified on behalf of the organization represented by the bot. Returns True on success.", + "Fields": [ + { + "OriginalName": "chat_id", + "ConvertedName": "ChatId", + "Description": "Unique identifier for the target chat or username of the target channel (in the format @channelusername)", + "OriginalFieldType": "Integer or String", + "ConvertedFieldType": "ChatId", + "Optional": false + } + ], + "OriginalReturnType": "True", + "ConvertedReturnType": "bool" + }, { "OriginalName": "answerInlineQuery", "ConvertedName": "AnswerInlineQuery", @@ -5158,6 +5476,63 @@ "OriginalReturnType": "SentWebAppMessage", "ConvertedReturnType": "SentWebAppMessage" }, + { + "OriginalName": "savePreparedInlineMessage", + "ConvertedName": "SavePreparedInlineMessage", + "Description": "Stores a message that can be sent by a user of a Mini App. Returns a PreparedInlineMessage object.", + "Fields": [ + { + "OriginalName": "user_id", + "ConvertedName": "UserId", + "Description": "Unique identifier of the target user that can use the prepared message", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": false + }, + { + "OriginalName": "result", + "ConvertedName": "Result", + "Description": "A JSON-serialized object describing the message to be sent", + "OriginalFieldType": "InlineQueryResult", + "ConvertedFieldType": "InlineQueryResult", + "Optional": false + }, + { + "OriginalName": "allow_user_chats", + "ConvertedName": "AllowUserChats", + "Description": "Pass True if the message can be sent to private chats with users", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, + { + "OriginalName": "allow_bot_chats", + "ConvertedName": "AllowBotChats", + "Description": "Pass True if the message can be sent to private chats with bots", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, + { + "OriginalName": "allow_group_chats", + "ConvertedName": "AllowGroupChats", + "Description": "Pass True if the message can be sent to group and supergroup chats", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, + { + "OriginalName": "allow_channel_chats", + "ConvertedName": "AllowChannelChats", + "Description": "Pass True if the message can be sent to channel chats", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + } + ], + "OriginalReturnType": "PreparedInlineMessage", + "ConvertedReturnType": "PreparedInlineMessage" + }, { "OriginalName": "sendInvoice", "ConvertedName": "SendInvoice", @@ -5363,6 +5738,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", @@ -5396,6 +5779,14 @@ "ConvertedName": "CreateInvoiceLink", "Description": "Use this method to create a link for an invoice. Returns the created invoice link as String on success.", "Fields": [ + { + "OriginalName": "business_connection_id", + "ConvertedName": "BusinessConnectionId", + "Description": "Unique identifier of the business connection on behalf of which the link will be created. For payments in Telegram Stars only.", + "OriginalFieldType": "String", + "ConvertedFieldType": "string", + "Optional": true + }, { "OriginalName": "title", "ConvertedName": "Title", @@ -5444,6 +5835,14 @@ "ConvertedFieldType": "LabeledPrice[]", "Optional": false }, + { + "OriginalName": "subscription_period", + "ConvertedName": "SubscriptionPeriod", + "Description": "The number of seconds the subscription will be active for before the next payment. The currency must be set to \u201CXTR\u201D (Telegram Stars) if the parameter is used. Currently, it must always be 2592000 (30 days) if specified. Any number of subscriptions can be active for a given bot at the same time, including multiple concurrent subscriptions from the same user. Subscription price must no exceed 2500 Telegram Stars.", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": true + }, { "OriginalName": "max_tip_amount", "ConvertedName": "MaxTipAmount", @@ -5592,7 +5991,7 @@ { "OriginalName": "error_message", "ConvertedName": "ErrorMessage", - "Description": "Required if ok is False. Error message in human readable form that explains why it is impossible to complete the order (e.g. \u0022Sorry, delivery to your desired address is unavailable\u0027). Telegram will display this message to the user.", + "Description": "Required if ok is False. Error message in human readable form that explains why it is impossible to complete the order (e.g. \u201CSorry, delivery to your desired address is unavailable\u201D). Telegram will display this message to the user.", "OriginalFieldType": "String", "ConvertedFieldType": "string", "Optional": true @@ -5684,6 +6083,39 @@ "OriginalReturnType": "True", "ConvertedReturnType": "bool" }, + { + "OriginalName": "editUserStarSubscription", + "ConvertedName": "EditUserStarSubscription", + "Description": "Allows the bot to cancel or re-enable extension of a subscription paid in Telegram Stars. Returns True on success.", + "Fields": [ + { + "OriginalName": "user_id", + "ConvertedName": "UserId", + "Description": "Identifier of the user whose subscription will be edited", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": false + }, + { + "OriginalName": "telegram_payment_charge_id", + "ConvertedName": "TelegramPaymentChargeId", + "Description": "Telegram payment identifier for the subscription", + "OriginalFieldType": "String", + "ConvertedFieldType": "string", + "Optional": false + }, + { + "OriginalName": "is_canceled", + "ConvertedName": "IsCanceled", + "Description": "Pass True to cancel extension of the user subscription; the subscription must be active up to the end of the current subscription period. Pass False to allow the user to re-enable a subscription that was previously canceled by the bot.", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": false + } + ], + "OriginalReturnType": "True", + "ConvertedReturnType": "bool" + }, { "OriginalName": "setPassportDataErrors", "ConvertedName": "SetPassportDataErrors", @@ -5762,6 +6194,14 @@ "ConvertedFieldType": "bool", "Optional": true }, + { + "OriginalName": "allow_paid_broadcast", + "ConvertedName": "AllowPaidBroadcast", + "Description": "Pass True to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot\u0027s balance", + "OriginalFieldType": "Boolean", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "message_effect_id", "ConvertedName": "MessageEffectId", diff --git a/src/Funogram.Generator/out/types.json b/src/Funogram.Generator/out/types.json index b7544f4..4683228 100644 --- a/src/Funogram.Generator/out/types.json +++ b/src/Funogram.Generator/out/types.json @@ -840,7 +840,7 @@ { "OriginalName": "message_id", "ConvertedName": "MessageId", - "Description": "Unique message identifier inside this chat", + "Description": "Unique message identifier inside this chat. In specific instances (e.g., message containing a video sent to a big chat), the server might automatically schedule a message instead of sending it immediately. In such cases, this field will be 0 and the relevant message will be unusable until it is actually sent", "OriginalFieldType": "Integer", "ConvertedFieldType": "int64", "Optional": false @@ -1531,7 +1531,7 @@ { "OriginalName": "message_id", "ConvertedName": "MessageId", - "Description": "Unique message identifier", + "Description": "Unique message identifier. In specific instances (e.g., message containing a video sent to a big chat), the server might automatically schedule a message instead of sending it immediately. In such cases, this field will be 0 and the relevant message will be unusable until it is actually sent", "OriginalFieldType": "Integer", "ConvertedFieldType": "int64", "Optional": false @@ -1604,7 +1604,7 @@ { "OriginalName": "type", "ConvertedName": "Type", - "Description": "Type of the entity. Currently, can be \u201Cmention\u201D (@username), \u201Chashtag\u201D (#hashtag), \u201Ccashtag\u201D ($USD), \u201Cbot_command\u201D (/start@jobs_bot), \u201Curl\u201D (https://telegram.org), \u201Cemail\u201D (do-not-reply@telegram.org), \u201Cphone_number\u201D (\u002B1-212-555-0123), \u201Cbold\u201D (bold text), \u201Citalic\u201D (italic text), \u201Cunderline\u201D (underlined text), \u201Cstrikethrough\u201D (strikethrough text), \u201Cspoiler\u201D (spoiler message), \u201Cblockquote\u201D (block quotation), \u201Cexpandable_blockquote\u201D (collapsed-by-default block quotation), \u201Ccode\u201D (monowidth string), \u201Cpre\u201D (monowidth block), \u201Ctext_link\u201D (for clickable text URLs), \u201Ctext_mention\u201D (for users without usernames), \u201Ccustom_emoji\u201D (for inline custom emoji stickers)", + "Description": "Type of the entity. Currently, can be \u201Cmention\u201D (@username), \u201Chashtag\u201D (#hashtag or #hashtag@chatusername), \u201Ccashtag\u201D ($USD or $USD@chatusername), \u201Cbot_command\u201D (/start@jobs_bot), \u201Curl\u201D (https://telegram.org), \u201Cemail\u201D (do-not-reply@telegram.org), \u201Cphone_number\u201D (\u002B1-212-555-0123), \u201Cbold\u201D (bold text), \u201Citalic\u201D (italic text), \u201Cunderline\u201D (underlined text), \u201Cstrikethrough\u201D (strikethrough text), \u201Cspoiler\u201D (spoiler message), \u201Cblockquote\u201D (block quotation), \u201Cexpandable_blockquote\u201D (collapsed-by-default block quotation), \u201Ccode\u201D (monowidth string), \u201Cpre\u201D (monowidth block), \u201Ctext_link\u201D (for clickable text URLs), \u201Ctext_mention\u201D (for users without usernames), \u201Ccustom_emoji\u201D (for inline custom emoji stickers)", "OriginalFieldType": "String", "ConvertedFieldType": "string", "Optional": false @@ -3583,7 +3583,7 @@ }, { "Name": "BackgroundTypePattern", - "Description": "The background is a PNG or TGV (gzipped subset of SVG with MIME type \u201Capplication/x-tgwallpattern\u201D) pattern to be combined with the background fill chosen by the user.", + "Description": "The background is a .PNG or .TGV (gzipped subset of SVG with MIME type \u201Capplication/x-tgwallpattern\u201D) pattern to be combined with the background fill chosen by the user.", "Kind": { "Case": "Fields", "Fields": [ @@ -4824,6 +4824,14 @@ "ConvertedFieldType": "SwitchInlineQueryChosenChat", "Optional": true }, + { + "OriginalName": "copy_text", + "ConvertedName": "CopyText", + "Description": "Description of the button that copies the specified text to the clipboard.", + "OriginalFieldType": "CopyTextButton", + "ConvertedFieldType": "CopyTextButton", + "Optional": true + }, { "OriginalName": "callback_game", "ConvertedName": "CallbackGame", @@ -4938,6 +4946,25 @@ ] } }, + { + "Name": "CopyTextButton", + "Description": "This object represents an inline keyboard button that copies specified text to the clipboard.", + "Kind": { + "Case": "Fields", + "Fields": [ + [ + { + "OriginalName": "text", + "ConvertedName": "Text", + "Description": "The text to be copied to the clipboard; 1-256 characters", + "OriginalFieldType": "String", + "ConvertedFieldType": "string", + "Optional": false + } + ] + ] + } + }, { "Name": "CallbackQuery", "Description": "This object represents an incoming callback query from a callback button in an inline keyboard. If the button that originated the query was attached to a message sent by the bot, the field message will be present. If the button was attached to a message sent via the bot (in inline mode), the field inline_message_id will be present. Exactly one of the fields data or game_short_name will be present.", @@ -8115,7 +8142,7 @@ { "OriginalName": "format", "ConvertedName": "Format", - "Description": "Format of the added sticker, must be one of \u201Cstatic\u201D for a .WEBP or .PNG image, \u201Canimated\u201D for a .TGS animation, \u201Cvideo\u201D for a WEBM video", + "Description": "Format of the added sticker, must be one of \u201Cstatic\u201D for a .WEBP or .PNG image, \u201Canimated\u201D for a .TGS animation, \u201Cvideo\u201D for a .WEBM video", "OriginalFieldType": "String", "ConvertedFieldType": "string", "Optional": false @@ -8148,6 +8175,84 @@ ] } }, + { + "Name": "Gift", + "Description": "This object represents a gift that can be sent by the bot.", + "Kind": { + "Case": "Fields", + "Fields": [ + [ + { + "OriginalName": "id", + "ConvertedName": "Id", + "Description": "Unique identifier of the gift", + "OriginalFieldType": "String", + "ConvertedFieldType": "string", + "Optional": false + }, + { + "OriginalName": "sticker", + "ConvertedName": "Sticker", + "Description": "The sticker that represents the gift", + "OriginalFieldType": "Sticker", + "ConvertedFieldType": "Sticker", + "Optional": false + }, + { + "OriginalName": "star_count", + "ConvertedName": "StarCount", + "Description": "The number of Telegram Stars that must be paid to send the sticker", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": false + }, + { + "OriginalName": "upgrade_star_count", + "ConvertedName": "UpgradeStarCount", + "Description": "The number of Telegram Stars that must be paid to upgrade the gift to a unique one", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": true + }, + { + "OriginalName": "total_count", + "ConvertedName": "TotalCount", + "Description": "The total number of the gifts of this type that can be sent; for limited gifts only", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": true + }, + { + "OriginalName": "remaining_count", + "ConvertedName": "RemainingCount", + "Description": "The number of remaining gifts of this type that can be sent; for limited gifts only", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": true + } + ] + ] + } + }, + { + "Name": "Gifts", + "Description": "This object represent a list of gifts.", + "Kind": { + "Case": "Fields", + "Fields": [ + [ + { + "OriginalName": "gifts", + "ConvertedName": "Gifts", + "Description": "The list of gifts", + "OriginalFieldType": "Array of Gift", + "ConvertedFieldType": "Gift[]", + "Optional": false + } + ] + ] + } + }, { "Name": "InlineQuery", "Description": "This object represents an incoming inline query. When the user sends an empty query, your bot could return some default or trending results.", @@ -8388,14 +8493,6 @@ "ConvertedFieldType": "string", "Optional": true }, - { - "OriginalName": "hide_url", - "ConvertedName": "HideUrl", - "Description": "Pass True if you don\u0027t want the URL to be shown in the message", - "OriginalFieldType": "Boolean", - "ConvertedFieldType": "bool", - "Optional": true - }, { "OriginalName": "description", "ConvertedName": "Description", @@ -8581,7 +8678,7 @@ { "OriginalName": "gif_url", "ConvertedName": "GifUrl", - "Description": "A valid URL for the GIF file. File size must not exceed 1MB", + "Description": "A valid URL for the GIF file", "OriginalFieldType": "String", "ConvertedFieldType": "string", "Optional": false @@ -8712,7 +8809,7 @@ { "OriginalName": "mpeg4_url", "ConvertedName": "Mpeg4Url", - "Description": "A valid URL for the MPEG4 file. File size must not exceed 1MB", + "Description": "A valid URL for the MPEG4 file", "OriginalFieldType": "String", "ConvertedFieldType": "string", "Optional": false @@ -10820,7 +10917,7 @@ }, { "Name": "SentWebAppMessage", - "Description": "Describes an inline message sent by a Web App on behalf of a user.\nYour bot can accept payments from Telegram users. Please see the introduction to payments for more details on the process and how to set up payments for your bot.", + "Description": "Describes an inline message sent by a Web App on behalf of a user.", "Kind": { "Case": "Fields", "Fields": [ @@ -10837,6 +10934,33 @@ ] } }, + { + "Name": "PreparedInlineMessage", + "Description": "Describes an inline message to be sent by a user of a Mini App.\nYour bot can accept payments from Telegram users. Please see the introduction to payments for more details on the process and how to set up payments for your bot.", + "Kind": { + "Case": "Fields", + "Fields": [ + [ + { + "OriginalName": "id", + "ConvertedName": "Id", + "Description": "Unique identifier of the prepared message", + "OriginalFieldType": "String", + "ConvertedFieldType": "string", + "Optional": false + }, + { + "OriginalName": "expiration_date", + "ConvertedName": "ExpirationDate", + "Description": "Expiration date of the prepared message, in Unix time. Expired prepared messages can no longer be used", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": false + } + ] + ] + } + }, { "Name": "LabeledPrice", "Description": "This object represents a portion of the price for goods or services.", @@ -11054,7 +11178,7 @@ }, { "Name": "SuccessfulPayment", - "Description": "This object contains basic information about a successful payment.", + "Description": "This object contains basic information about a successful payment. Note that if the buyer initiates a chargeback with the relevant payment provider following this transaction, the funds may be debited from your balance. This is outside of Telegram\u0027s control.", "Kind": { "Case": "Fields", "Fields": [ @@ -11083,6 +11207,30 @@ "ConvertedFieldType": "string", "Optional": false }, + { + "OriginalName": "subscription_expiration_date", + "ConvertedName": "SubscriptionExpirationDate", + "Description": "Expiration date of the subscription, in Unix time; for recurring payments only", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": true + }, + { + "OriginalName": "is_recurring", + "ConvertedName": "IsRecurring", + "Description": "True, if the payment is a recurring payment for a subscription", + "OriginalFieldType": "True", + "ConvertedFieldType": "bool", + "Optional": true + }, + { + "OriginalName": "is_first_recurring", + "ConvertedName": "IsFirstRecurring", + "Description": "True, if the payment is the first payment for a subscription", + "OriginalFieldType": "True", + "ConvertedFieldType": "bool", + "Optional": true + }, { "OriginalName": "shipping_option_id", "ConvertedName": "ShippingOptionId", @@ -11403,6 +11551,57 @@ ] } }, + { + "Name": "AffiliateInfo", + "Description": "Contains information about the affiliate that received a commission via this transaction.", + "Kind": { + "Case": "Fields", + "Fields": [ + [ + { + "OriginalName": "affiliate_user", + "ConvertedName": "AffiliateUser", + "Description": "The bot or the user that received an affiliate commission if it was received by a bot or a user", + "OriginalFieldType": "User", + "ConvertedFieldType": "User", + "Optional": true + }, + { + "OriginalName": "affiliate_chat", + "ConvertedName": "AffiliateChat", + "Description": "The chat that received an affiliate commission if it was received by a chat", + "OriginalFieldType": "Chat", + "ConvertedFieldType": "Chat", + "Optional": true + }, + { + "OriginalName": "commission_per_mille", + "ConvertedName": "CommissionPerMille", + "Description": "The number of Telegram Stars received by the affiliate for each 1000 Telegram Stars received by the bot from referred users", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": false + }, + { + "OriginalName": "amount", + "ConvertedName": "Amount", + "Description": "Integer amount of Telegram Stars received by the affiliate from the transaction, rounded to 0; can be negative for refunds", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": false + }, + { + "OriginalName": "nanostar_amount", + "ConvertedName": "NanostarAmount", + "Description": "The number of 1/1000000000 shares of Telegram Stars received by the affiliate; from -999999999 to 999999999; can be negative for refunds", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": true + } + ] + ] + } + }, { "Name": "TransactionPartner", "Description": "This object describes the source of a transaction, or its recipient for outgoing transactions. Currently, it can be one of", @@ -11414,6 +11613,10 @@ "Name": "User", "CaseType": "TransactionPartnerUser" }, + { + "Name": "AffiliateProgram", + "CaseType": "TransactionPartnerAffiliateProgram" + }, { "Name": "Fragment", "CaseType": "TransactionPartnerFragment" @@ -11422,6 +11625,10 @@ "Name": "TelegramAds", "CaseType": "TransactionPartnerTelegramAds" }, + { + "Name": "TelegramApi", + "CaseType": "TransactionPartnerTelegramApi" + }, { "Name": "Other", "CaseType": "TransactionPartnerOther" @@ -11453,6 +11660,14 @@ "ConvertedFieldType": "User", "Optional": false }, + { + "OriginalName": "affiliate", + "ConvertedName": "Affiliate", + "Description": "Information about the affiliate that received a commission via this transaction", + "OriginalFieldType": "AffiliateInfo", + "ConvertedFieldType": "AffiliateInfo", + "Optional": true + }, { "OriginalName": "invoice_payload", "ConvertedName": "InvoicePayload", @@ -11461,6 +11676,14 @@ "ConvertedFieldType": "string", "Optional": true }, + { + "OriginalName": "subscription_period", + "ConvertedName": "SubscriptionPeriod", + "Description": "The duration of the paid subscription", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": true + }, { "OriginalName": "paid_media", "ConvertedName": "PaidMedia", @@ -11476,6 +11699,49 @@ "OriginalFieldType": "String", "ConvertedFieldType": "string", "Optional": true + }, + { + "OriginalName": "gift", + "ConvertedName": "Gift", + "Description": "The gift sent to the user by the bot", + "OriginalFieldType": "Gift", + "ConvertedFieldType": "Gift", + "Optional": true + } + ] + ] + } + }, + { + "Name": "TransactionPartnerAffiliateProgram", + "Description": "Describes the affiliate program that issued the affiliate commission received via this transaction.", + "Kind": { + "Case": "Fields", + "Fields": [ + [ + { + "OriginalName": "type", + "ConvertedName": "Type", + "Description": "Type of the transaction partner, always \u201Caffiliate_program\u201D", + "OriginalFieldType": "String", + "ConvertedFieldType": "string", + "Optional": false + }, + { + "OriginalName": "sponsor_user", + "ConvertedName": "SponsorUser", + "Description": "Information about the bot that sponsored the affiliate program", + "OriginalFieldType": "User", + "ConvertedFieldType": "User", + "Optional": true + }, + { + "OriginalName": "commission_per_mille", + "ConvertedName": "CommissionPerMille", + "Description": "The number of Telegram Stars received by the bot for each 1000 Telegram Stars received by the affiliate program sponsor from referred users", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": false } ] ] @@ -11527,6 +11793,33 @@ ] } }, + { + "Name": "TransactionPartnerTelegramApi", + "Description": "Describes a transaction with payment for paid broadcasting.", + "Kind": { + "Case": "Fields", + "Fields": [ + [ + { + "OriginalName": "type", + "ConvertedName": "Type", + "Description": "Type of the transaction partner, always \u201Ctelegram_api\u201D", + "OriginalFieldType": "String", + "ConvertedFieldType": "string", + "Optional": false + }, + { + "OriginalName": "request_count", + "ConvertedName": "RequestCount", + "Description": "The number of successful requests that exceeded regular limits and were therefore billed", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": false + } + ] + ] + } + }, { "Name": "TransactionPartnerOther", "Description": "Describes a transaction with an unknown source or recipient.", @@ -11548,7 +11841,7 @@ }, { "Name": "StarTransaction", - "Description": "Describes a Telegram Star transaction.", + "Description": "Describes a Telegram Star transaction. Note that if the buyer initiates a chargeback with the payment provider from whom they acquired Stars (e.g., Apple, Google) following this transaction, the refunded Stars will be deducted from the bot\u0027s balance. This is outside of Telegram\u0027s control.", "Kind": { "Case": "Fields", "Fields": [ @@ -11556,7 +11849,7 @@ { "OriginalName": "id", "ConvertedName": "Id", - "Description": "Unique identifier of the transaction. Coincides with the identifer of the original transaction for refund transactions. Coincides with SuccessfulPayment.telegram_payment_charge_id for successful incoming payments from users.", + "Description": "Unique identifier of the transaction. Coincides with the identifier of the original transaction for refund transactions. Coincides with SuccessfulPayment.telegram_payment_charge_id for successful incoming payments from users.", "OriginalFieldType": "String", "ConvertedFieldType": "string", "Optional": false @@ -11564,11 +11857,19 @@ { "OriginalName": "amount", "ConvertedName": "Amount", - "Description": "Number of Telegram Stars transferred by the transaction", + "Description": "Integer amount of Telegram Stars transferred by the transaction", "OriginalFieldType": "Integer", "ConvertedFieldType": "int64", "Optional": false }, + { + "OriginalName": "nanostar_amount", + "ConvertedName": "NanostarAmount", + "Description": "The number of 1/1000000000 shares of Telegram Stars transferred by the transaction; from 0 to 999999999", + "OriginalFieldType": "Integer", + "ConvertedFieldType": "int64", + "Optional": true + }, { "OriginalName": "date", "ConvertedName": "Date", diff --git a/src/Funogram.Telegram/Directory.Build.props b/src/Funogram.Telegram/Directory.Build.props index 0acf47b..a26aa14 100644 --- a/src/Funogram.Telegram/Directory.Build.props +++ b/src/Funogram.Telegram/Directory.Build.props @@ -1,7 +1,7 @@  - 7.10.0.0 + 8.2.0.0 Nikolay Matyushin Funogram.Telegram Funogram.Telegram diff --git a/src/Funogram.Telegram/RequestsTypes.fs b/src/Funogram.Telegram/RequestsTypes.fs index c15ead2..5f5bb8a 100644 --- a/src/Funogram.Telegram/RequestsTypes.fs +++ b/src/Funogram.Telegram/RequestsTypes.fs @@ -87,11 +87,12 @@ type SendMessage = LinkPreviewOptions: LinkPreviewOptions option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, text: string, ?businessConnectionId: string, ?messageThreadId: int64, ?parseMode: ParseMode, ?entities: MessageEntity[], ?linkPreviewOptions: LinkPreviewOptions, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, text: string, ?businessConnectionId: string, ?messageThreadId: int64, ?parseMode: ParseMode, ?entities: MessageEntity[], ?linkPreviewOptions: LinkPreviewOptions, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -102,14 +103,15 @@ type SendMessage = LinkPreviewOptions = linkPreviewOptions DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, text: string, ?businessConnectionId: string, ?messageThreadId: int64, ?parseMode: ParseMode, ?entities: MessageEntity[], ?linkPreviewOptions: LinkPreviewOptions, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendMessage.Make(ChatId.Int chatId, text, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?parseMode = parseMode, ?entities = entities, ?linkPreviewOptions = linkPreviewOptions, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) - static member Make(chatId: string, text: string, ?businessConnectionId: string, ?messageThreadId: int64, ?parseMode: ParseMode, ?entities: MessageEntity[], ?linkPreviewOptions: LinkPreviewOptions, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendMessage.Make(ChatId.String chatId, text, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?parseMode = parseMode, ?entities = entities, ?linkPreviewOptions = linkPreviewOptions, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, text: string, ?businessConnectionId: string, ?messageThreadId: int64, ?parseMode: ParseMode, ?entities: MessageEntity[], ?linkPreviewOptions: LinkPreviewOptions, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendMessage.Make(ChatId.Int chatId, text, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?parseMode = parseMode, ?entities = entities, ?linkPreviewOptions = linkPreviewOptions, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: string, text: string, ?businessConnectionId: string, ?messageThreadId: int64, ?parseMode: ParseMode, ?entities: MessageEntity[], ?linkPreviewOptions: LinkPreviewOptions, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendMessage.Make(ChatId.String chatId, text, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?parseMode = parseMode, ?entities = entities, ?linkPreviewOptions = linkPreviewOptions, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendMessage" @@ -175,10 +177,11 @@ type CopyMessage = ShowCaptionAboveMedia: bool option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, fromChatId: ChatId, messageId: int64, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?disableNotification: bool, ?protectContent: bool, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, fromChatId: ChatId, messageId: int64, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = { ChatId = chatId MessageThreadId = messageThreadId @@ -190,13 +193,14 @@ type CopyMessage = ShowCaptionAboveMedia = showCaptionAboveMedia DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, fromChatId: int64, messageId: int64, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?disableNotification: bool, ?protectContent: bool, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - CopyMessage.Make(ChatId.Int chatId, ChatId.Int fromChatId, messageId, ?messageThreadId = messageThreadId, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?showCaptionAboveMedia = showCaptionAboveMedia, ?disableNotification = disableNotification, ?protectContent = protectContent, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) - static member Make(chatId: string, fromChatId: string, messageId: int64, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?disableNotification: bool, ?protectContent: bool, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - CopyMessage.Make(ChatId.String chatId, ChatId.String fromChatId, messageId, ?messageThreadId = messageThreadId, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?showCaptionAboveMedia = showCaptionAboveMedia, ?disableNotification = disableNotification, ?protectContent = protectContent, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, fromChatId: int64, messageId: int64, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + CopyMessage.Make(ChatId.Int chatId, ChatId.Int fromChatId, messageId, ?messageThreadId = messageThreadId, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?showCaptionAboveMedia = showCaptionAboveMedia, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: string, fromChatId: string, messageId: int64, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + CopyMessage.Make(ChatId.String chatId, ChatId.String fromChatId, messageId, ?messageThreadId = messageThreadId, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?showCaptionAboveMedia = showCaptionAboveMedia, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "copyMessage" @@ -240,11 +244,12 @@ type SendPhoto = HasSpoiler: bool option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, photo: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?hasSpoiler: bool, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, photo: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?hasSpoiler: bool, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -257,14 +262,15 @@ type SendPhoto = HasSpoiler = hasSpoiler DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, photo: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?hasSpoiler: bool, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendPhoto.Make(ChatId.Int chatId, photo, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?showCaptionAboveMedia = showCaptionAboveMedia, ?hasSpoiler = hasSpoiler, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) - static member Make(chatId: string, photo: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?hasSpoiler: bool, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendPhoto.Make(ChatId.String chatId, photo, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?showCaptionAboveMedia = showCaptionAboveMedia, ?hasSpoiler = hasSpoiler, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, photo: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?hasSpoiler: bool, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendPhoto.Make(ChatId.Int chatId, photo, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?showCaptionAboveMedia = showCaptionAboveMedia, ?hasSpoiler = hasSpoiler, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: string, photo: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?hasSpoiler: bool, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendPhoto.Make(ChatId.String chatId, photo, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?showCaptionAboveMedia = showCaptionAboveMedia, ?hasSpoiler = hasSpoiler, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendPhoto" @@ -283,11 +289,12 @@ type SendAudio = Thumbnail: InputFile option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, audio: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?duration: int64, ?performer: string, ?title: string, ?thumbnail: InputFile, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, audio: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?thumbnail: InputFile, ?title: string, ?performer: string, ?duration: int64, ?captionEntities: MessageEntity[], ?parseMode: ParseMode, ?caption: string, ?messageThreadId: int64, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -302,14 +309,15 @@ type SendAudio = Thumbnail = thumbnail DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, audio: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?duration: int64, ?performer: string, ?title: string, ?thumbnail: InputFile, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendAudio.Make(ChatId.Int chatId, audio, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?duration = duration, ?performer = performer, ?title = title, ?thumbnail = thumbnail, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) - static member Make(chatId: string, audio: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?duration: int64, ?performer: string, ?title: string, ?thumbnail: InputFile, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendAudio.Make(ChatId.String chatId, audio, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?duration = duration, ?performer = performer, ?title = title, ?thumbnail = thumbnail, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, audio: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?thumbnail: InputFile, ?title: string, ?performer: string, ?duration: int64, ?captionEntities: MessageEntity[], ?parseMode: ParseMode, ?caption: string, ?messageThreadId: int64, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendAudio.Make(ChatId.Int chatId, audio, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?allowPaidBroadcast = allowPaidBroadcast, ?protectContent = protectContent, ?disableNotification = disableNotification, ?thumbnail = thumbnail, ?title = title, ?performer = performer, ?duration = duration, ?captionEntities = captionEntities, ?parseMode = parseMode, ?caption = caption, ?messageThreadId = messageThreadId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: string, audio: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?thumbnail: InputFile, ?title: string, ?performer: string, ?duration: int64, ?captionEntities: MessageEntity[], ?parseMode: ParseMode, ?caption: string, ?messageThreadId: int64, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendAudio.Make(ChatId.String chatId, audio, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?allowPaidBroadcast = allowPaidBroadcast, ?protectContent = protectContent, ?disableNotification = disableNotification, ?thumbnail = thumbnail, ?title = title, ?performer = performer, ?duration = duration, ?captionEntities = captionEntities, ?parseMode = parseMode, ?caption = caption, ?messageThreadId = messageThreadId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendAudio" @@ -326,11 +334,12 @@ type SendDocument = DisableContentTypeDetection: bool option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, document: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?thumbnail: InputFile, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?disableContentTypeDetection: bool, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, document: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?thumbnail: InputFile, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?disableContentTypeDetection: bool, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -343,14 +352,15 @@ type SendDocument = DisableContentTypeDetection = disableContentTypeDetection DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, document: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?thumbnail: InputFile, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?disableContentTypeDetection: bool, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendDocument.Make(ChatId.Int chatId, document, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?thumbnail = thumbnail, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?disableContentTypeDetection = disableContentTypeDetection, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) - static member Make(chatId: string, document: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?thumbnail: InputFile, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?disableContentTypeDetection: bool, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendDocument.Make(ChatId.String chatId, document, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?thumbnail = thumbnail, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?disableContentTypeDetection = disableContentTypeDetection, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, document: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?thumbnail: InputFile, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?disableContentTypeDetection: bool, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendDocument.Make(ChatId.Int chatId, document, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?thumbnail = thumbnail, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?disableContentTypeDetection = disableContentTypeDetection, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: string, document: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?thumbnail: InputFile, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?disableContentTypeDetection: bool, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendDocument.Make(ChatId.String chatId, document, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?thumbnail = thumbnail, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?disableContentTypeDetection = disableContentTypeDetection, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendDocument" @@ -372,11 +382,12 @@ type SendVideo = SupportsStreaming: bool option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, video: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?protectContent: bool, ?disableNotification: bool, ?supportsStreaming: bool, ?hasSpoiler: bool, ?showCaptionAboveMedia: bool, ?captionEntities: MessageEntity[], ?parseMode: ParseMode, ?caption: string, ?thumbnail: InputFile, ?height: int64, ?width: int64, ?duration: int64, ?messageThreadId: int64, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, video: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?supportsStreaming: bool, ?hasSpoiler: bool, ?showCaptionAboveMedia: bool, ?parseMode: ParseMode, ?replyParameters: ReplyParameters, ?caption: string, ?thumbnail: InputFile, ?height: int64, ?width: int64, ?duration: int64, ?messageThreadId: int64, ?captionEntities: MessageEntity[], ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -394,14 +405,15 @@ type SendVideo = SupportsStreaming = supportsStreaming DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, video: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?protectContent: bool, ?disableNotification: bool, ?supportsStreaming: bool, ?hasSpoiler: bool, ?showCaptionAboveMedia: bool, ?captionEntities: MessageEntity[], ?parseMode: ParseMode, ?caption: string, ?thumbnail: InputFile, ?height: int64, ?width: int64, ?duration: int64, ?messageThreadId: int64, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendVideo.Make(ChatId.Int chatId, video, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?protectContent = protectContent, ?disableNotification = disableNotification, ?supportsStreaming = supportsStreaming, ?hasSpoiler = hasSpoiler, ?showCaptionAboveMedia = showCaptionAboveMedia, ?captionEntities = captionEntities, ?parseMode = parseMode, ?caption = caption, ?thumbnail = thumbnail, ?height = height, ?width = width, ?duration = duration, ?messageThreadId = messageThreadId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) - static member Make(chatId: string, video: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?protectContent: bool, ?disableNotification: bool, ?supportsStreaming: bool, ?hasSpoiler: bool, ?showCaptionAboveMedia: bool, ?captionEntities: MessageEntity[], ?parseMode: ParseMode, ?caption: string, ?thumbnail: InputFile, ?height: int64, ?width: int64, ?duration: int64, ?messageThreadId: int64, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendVideo.Make(ChatId.String chatId, video, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?protectContent = protectContent, ?disableNotification = disableNotification, ?supportsStreaming = supportsStreaming, ?hasSpoiler = hasSpoiler, ?showCaptionAboveMedia = showCaptionAboveMedia, ?captionEntities = captionEntities, ?parseMode = parseMode, ?caption = caption, ?thumbnail = thumbnail, ?height = height, ?width = width, ?duration = duration, ?messageThreadId = messageThreadId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, video: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?supportsStreaming: bool, ?hasSpoiler: bool, ?showCaptionAboveMedia: bool, ?parseMode: ParseMode, ?replyParameters: ReplyParameters, ?caption: string, ?thumbnail: InputFile, ?height: int64, ?width: int64, ?duration: int64, ?messageThreadId: int64, ?captionEntities: MessageEntity[], ?replyMarkup: Markup) = + SendVideo.Make(ChatId.Int chatId, video, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?allowPaidBroadcast = allowPaidBroadcast, ?protectContent = protectContent, ?disableNotification = disableNotification, ?supportsStreaming = supportsStreaming, ?hasSpoiler = hasSpoiler, ?showCaptionAboveMedia = showCaptionAboveMedia, ?parseMode = parseMode, ?replyParameters = replyParameters, ?caption = caption, ?thumbnail = thumbnail, ?height = height, ?width = width, ?duration = duration, ?messageThreadId = messageThreadId, ?captionEntities = captionEntities, ?replyMarkup = replyMarkup) + static member Make(chatId: string, video: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?supportsStreaming: bool, ?hasSpoiler: bool, ?showCaptionAboveMedia: bool, ?parseMode: ParseMode, ?replyParameters: ReplyParameters, ?caption: string, ?thumbnail: InputFile, ?height: int64, ?width: int64, ?duration: int64, ?messageThreadId: int64, ?captionEntities: MessageEntity[], ?replyMarkup: Markup) = + SendVideo.Make(ChatId.String chatId, video, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?allowPaidBroadcast = allowPaidBroadcast, ?protectContent = protectContent, ?disableNotification = disableNotification, ?supportsStreaming = supportsStreaming, ?hasSpoiler = hasSpoiler, ?showCaptionAboveMedia = showCaptionAboveMedia, ?parseMode = parseMode, ?replyParameters = replyParameters, ?caption = caption, ?thumbnail = thumbnail, ?height = height, ?width = width, ?duration = duration, ?messageThreadId = messageThreadId, ?captionEntities = captionEntities, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendVideo" @@ -422,11 +434,12 @@ type SendAnimation = HasSpoiler: bool option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, animation: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?protectContent: bool, ?disableNotification: bool, ?hasSpoiler: bool, ?showCaptionAboveMedia: bool, ?captionEntities: MessageEntity[], ?caption: string, ?replyParameters: ReplyParameters, ?thumbnail: InputFile, ?height: int64, ?width: int64, ?duration: int64, ?messageThreadId: int64, ?parseMode: ParseMode, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, animation: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?hasSpoiler: bool, ?showCaptionAboveMedia: bool, ?captionEntities: MessageEntity[], ?parseMode: ParseMode, ?caption: string, ?thumbnail: InputFile, ?height: int64, ?width: int64, ?duration: int64, ?messageThreadId: int64, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -443,14 +456,15 @@ type SendAnimation = HasSpoiler = hasSpoiler DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, animation: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?protectContent: bool, ?disableNotification: bool, ?hasSpoiler: bool, ?showCaptionAboveMedia: bool, ?captionEntities: MessageEntity[], ?caption: string, ?replyParameters: ReplyParameters, ?thumbnail: InputFile, ?height: int64, ?width: int64, ?duration: int64, ?messageThreadId: int64, ?parseMode: ParseMode, ?replyMarkup: Markup) = - SendAnimation.Make(ChatId.Int chatId, animation, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?protectContent = protectContent, ?disableNotification = disableNotification, ?hasSpoiler = hasSpoiler, ?showCaptionAboveMedia = showCaptionAboveMedia, ?captionEntities = captionEntities, ?caption = caption, ?replyParameters = replyParameters, ?thumbnail = thumbnail, ?height = height, ?width = width, ?duration = duration, ?messageThreadId = messageThreadId, ?parseMode = parseMode, ?replyMarkup = replyMarkup) - static member Make(chatId: string, animation: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?protectContent: bool, ?disableNotification: bool, ?hasSpoiler: bool, ?showCaptionAboveMedia: bool, ?captionEntities: MessageEntity[], ?caption: string, ?replyParameters: ReplyParameters, ?thumbnail: InputFile, ?height: int64, ?width: int64, ?duration: int64, ?messageThreadId: int64, ?parseMode: ParseMode, ?replyMarkup: Markup) = - SendAnimation.Make(ChatId.String chatId, animation, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?protectContent = protectContent, ?disableNotification = disableNotification, ?hasSpoiler = hasSpoiler, ?showCaptionAboveMedia = showCaptionAboveMedia, ?captionEntities = captionEntities, ?caption = caption, ?replyParameters = replyParameters, ?thumbnail = thumbnail, ?height = height, ?width = width, ?duration = duration, ?messageThreadId = messageThreadId, ?parseMode = parseMode, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, animation: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?hasSpoiler: bool, ?showCaptionAboveMedia: bool, ?captionEntities: MessageEntity[], ?parseMode: ParseMode, ?caption: string, ?thumbnail: InputFile, ?height: int64, ?width: int64, ?duration: int64, ?messageThreadId: int64, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendAnimation.Make(ChatId.Int chatId, animation, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?allowPaidBroadcast = allowPaidBroadcast, ?protectContent = protectContent, ?disableNotification = disableNotification, ?hasSpoiler = hasSpoiler, ?showCaptionAboveMedia = showCaptionAboveMedia, ?captionEntities = captionEntities, ?parseMode = parseMode, ?caption = caption, ?thumbnail = thumbnail, ?height = height, ?width = width, ?duration = duration, ?messageThreadId = messageThreadId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: string, animation: InputFile, ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?hasSpoiler: bool, ?showCaptionAboveMedia: bool, ?captionEntities: MessageEntity[], ?parseMode: ParseMode, ?caption: string, ?thumbnail: InputFile, ?height: int64, ?width: int64, ?duration: int64, ?messageThreadId: int64, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendAnimation.Make(ChatId.String chatId, animation, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?allowPaidBroadcast = allowPaidBroadcast, ?protectContent = protectContent, ?disableNotification = disableNotification, ?hasSpoiler = hasSpoiler, ?showCaptionAboveMedia = showCaptionAboveMedia, ?captionEntities = captionEntities, ?parseMode = parseMode, ?caption = caption, ?thumbnail = thumbnail, ?height = height, ?width = width, ?duration = duration, ?messageThreadId = messageThreadId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendAnimation" @@ -466,11 +480,12 @@ type SendVoice = Duration: int64 option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, voice: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?duration: int64, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, voice: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?duration: int64, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -482,14 +497,15 @@ type SendVoice = Duration = duration DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, voice: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?duration: int64, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendVoice.Make(ChatId.Int chatId, voice, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?duration = duration, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) - static member Make(chatId: string, voice: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?duration: int64, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendVoice.Make(ChatId.String chatId, voice, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?duration = duration, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, voice: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?duration: int64, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendVoice.Make(ChatId.Int chatId, voice, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?duration = duration, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: string, voice: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?duration: int64, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendVoice.Make(ChatId.String chatId, voice, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?duration = duration, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendVoice" @@ -504,11 +520,12 @@ type SendVideoNote = Thumbnail: InputFile option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, videoNote: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?duration: int64, ?length: int64, ?thumbnail: InputFile, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, videoNote: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?duration: int64, ?length: int64, ?thumbnail: InputFile, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -519,14 +536,15 @@ type SendVideoNote = Thumbnail = thumbnail DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, videoNote: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?duration: int64, ?length: int64, ?thumbnail: InputFile, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendVideoNote.Make(ChatId.Int chatId, videoNote, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?duration = duration, ?length = length, ?thumbnail = thumbnail, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) - static member Make(chatId: string, videoNote: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?duration: int64, ?length: int64, ?thumbnail: InputFile, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendVideoNote.Make(ChatId.String chatId, videoNote, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?duration = duration, ?length = length, ?thumbnail = thumbnail, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, videoNote: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?duration: int64, ?length: int64, ?thumbnail: InputFile, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendVideoNote.Make(ChatId.Int chatId, videoNote, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?duration = duration, ?length = length, ?thumbnail = thumbnail, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: string, videoNote: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?duration: int64, ?length: int64, ?thumbnail: InputFile, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendVideoNote.Make(ChatId.String chatId, videoNote, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?duration = duration, ?length = length, ?thumbnail = thumbnail, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendVideoNote" @@ -543,10 +561,11 @@ type SendPaidMedia = ShowCaptionAboveMedia: bool option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, starCount: int64, media: InputPaidMedia[], ?businessConnectionId: string, ?payload: string, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?disableNotification: bool, ?protectContent: bool, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, starCount: int64, media: InputPaidMedia[], ?businessConnectionId: string, ?payload: string, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -559,13 +578,14 @@ type SendPaidMedia = ShowCaptionAboveMedia = showCaptionAboveMedia DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, starCount: int64, media: InputPaidMedia[], ?businessConnectionId: string, ?payload: string, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?disableNotification: bool, ?protectContent: bool, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendPaidMedia.Make(ChatId.Int chatId, starCount, media, ?businessConnectionId = businessConnectionId, ?payload = payload, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?showCaptionAboveMedia = showCaptionAboveMedia, ?disableNotification = disableNotification, ?protectContent = protectContent, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) - static member Make(chatId: string, starCount: int64, media: InputPaidMedia[], ?businessConnectionId: string, ?payload: string, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?disableNotification: bool, ?protectContent: bool, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendPaidMedia.Make(ChatId.String chatId, starCount, media, ?businessConnectionId = businessConnectionId, ?payload = payload, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?showCaptionAboveMedia = showCaptionAboveMedia, ?disableNotification = disableNotification, ?protectContent = protectContent, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, starCount: int64, media: InputPaidMedia[], ?businessConnectionId: string, ?payload: string, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendPaidMedia.Make(ChatId.Int chatId, starCount, media, ?businessConnectionId = businessConnectionId, ?payload = payload, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?showCaptionAboveMedia = showCaptionAboveMedia, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: string, starCount: int64, media: InputPaidMedia[], ?businessConnectionId: string, ?payload: string, ?caption: string, ?parseMode: ParseMode, ?captionEntities: MessageEntity[], ?showCaptionAboveMedia: bool, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendPaidMedia.Make(ChatId.String chatId, starCount, media, ?businessConnectionId = businessConnectionId, ?payload = payload, ?caption = caption, ?parseMode = parseMode, ?captionEntities = captionEntities, ?showCaptionAboveMedia = showCaptionAboveMedia, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendPaidMedia" @@ -577,10 +597,11 @@ type SendMediaGroup = Media: InputMedia[] DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option } - static member Make(chatId: ChatId, media: InputMedia[], ?businessConnectionId: string, ?messageThreadId: int64, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters) = + static member Make(chatId: ChatId, media: InputMedia[], ?businessConnectionId: string, ?messageThreadId: int64, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -588,13 +609,14 @@ type SendMediaGroup = Media = media DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters } - static member Make(chatId: int64, media: InputMedia[], ?businessConnectionId: string, ?messageThreadId: int64, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters) = - SendMediaGroup.Make(ChatId.Int chatId, media, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters) - static member Make(chatId: string, media: InputMedia[], ?businessConnectionId: string, ?messageThreadId: int64, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters) = - SendMediaGroup.Make(ChatId.String chatId, media, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters) + static member Make(chatId: int64, media: InputMedia[], ?businessConnectionId: string, ?messageThreadId: int64, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters) = + SendMediaGroup.Make(ChatId.Int chatId, media, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters) + static member Make(chatId: string, media: InputMedia[], ?businessConnectionId: string, ?messageThreadId: int64, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters) = + SendMediaGroup.Make(ChatId.String chatId, media, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters) interface IRequestBase with member _.MethodName = "sendMediaGroup" @@ -611,11 +633,12 @@ type SendLocation = ProximityAlertRadius: int64 option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, latitude: float, longitude: float, ?businessConnectionId: string, ?messageThreadId: int64, ?horizontalAccuracy: float, ?livePeriod: int64, ?heading: int64, ?proximityAlertRadius: int64, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, latitude: float, longitude: float, ?businessConnectionId: string, ?messageThreadId: int64, ?horizontalAccuracy: float, ?livePeriod: int64, ?heading: int64, ?proximityAlertRadius: int64, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -628,14 +651,15 @@ type SendLocation = ProximityAlertRadius = proximityAlertRadius DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, latitude: float, longitude: float, ?businessConnectionId: string, ?messageThreadId: int64, ?horizontalAccuracy: float, ?livePeriod: int64, ?heading: int64, ?proximityAlertRadius: int64, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendLocation.Make(ChatId.Int chatId, latitude, longitude, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?horizontalAccuracy = horizontalAccuracy, ?livePeriod = livePeriod, ?heading = heading, ?proximityAlertRadius = proximityAlertRadius, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) - static member Make(chatId: string, latitude: float, longitude: float, ?businessConnectionId: string, ?messageThreadId: int64, ?horizontalAccuracy: float, ?livePeriod: int64, ?heading: int64, ?proximityAlertRadius: int64, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendLocation.Make(ChatId.String chatId, latitude, longitude, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?horizontalAccuracy = horizontalAccuracy, ?livePeriod = livePeriod, ?heading = heading, ?proximityAlertRadius = proximityAlertRadius, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, latitude: float, longitude: float, ?businessConnectionId: string, ?messageThreadId: int64, ?horizontalAccuracy: float, ?livePeriod: int64, ?heading: int64, ?proximityAlertRadius: int64, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendLocation.Make(ChatId.Int chatId, latitude, longitude, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?horizontalAccuracy = horizontalAccuracy, ?livePeriod = livePeriod, ?heading = heading, ?proximityAlertRadius = proximityAlertRadius, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: string, latitude: float, longitude: float, ?businessConnectionId: string, ?messageThreadId: int64, ?horizontalAccuracy: float, ?livePeriod: int64, ?heading: int64, ?proximityAlertRadius: int64, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendLocation.Make(ChatId.String chatId, latitude, longitude, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?horizontalAccuracy = horizontalAccuracy, ?livePeriod = livePeriod, ?heading = heading, ?proximityAlertRadius = proximityAlertRadius, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendLocation" @@ -654,11 +678,12 @@ type SendVenue = GooglePlaceType: string option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, latitude: float, longitude: float, title: string, address: string, ?businessConnectionId: string, ?messageThreadId: int64, ?foursquareId: string, ?foursquareType: string, ?googlePlaceId: string, ?googlePlaceType: string, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, latitude: float, longitude: float, title: string, address: string, ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?foursquareType: string, ?googlePlaceId: string, ?replyParameters: ReplyParameters, ?foursquareId: string, ?messageThreadId: int64, ?googlePlaceType: string, ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -673,14 +698,15 @@ type SendVenue = GooglePlaceType = googlePlaceType DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, latitude: float, longitude: float, title: string, address: string, ?businessConnectionId: string, ?messageThreadId: int64, ?foursquareId: string, ?foursquareType: string, ?googlePlaceId: string, ?googlePlaceType: string, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendVenue.Make(ChatId.Int chatId, latitude, longitude, title, address, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?foursquareId = foursquareId, ?foursquareType = foursquareType, ?googlePlaceId = googlePlaceId, ?googlePlaceType = googlePlaceType, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) - static member Make(chatId: string, latitude: float, longitude: float, title: string, address: string, ?businessConnectionId: string, ?messageThreadId: int64, ?foursquareId: string, ?foursquareType: string, ?googlePlaceId: string, ?googlePlaceType: string, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendVenue.Make(ChatId.String chatId, latitude, longitude, title, address, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?foursquareId = foursquareId, ?foursquareType = foursquareType, ?googlePlaceId = googlePlaceId, ?googlePlaceType = googlePlaceType, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, latitude: float, longitude: float, title: string, address: string, ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?foursquareType: string, ?googlePlaceId: string, ?replyParameters: ReplyParameters, ?foursquareId: string, ?messageThreadId: int64, ?googlePlaceType: string, ?replyMarkup: Markup) = + SendVenue.Make(ChatId.Int chatId, latitude, longitude, title, address, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?allowPaidBroadcast = allowPaidBroadcast, ?protectContent = protectContent, ?disableNotification = disableNotification, ?foursquareType = foursquareType, ?googlePlaceId = googlePlaceId, ?replyParameters = replyParameters, ?foursquareId = foursquareId, ?messageThreadId = messageThreadId, ?googlePlaceType = googlePlaceType, ?replyMarkup = replyMarkup) + static member Make(chatId: string, latitude: float, longitude: float, title: string, address: string, ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?foursquareType: string, ?googlePlaceId: string, ?replyParameters: ReplyParameters, ?foursquareId: string, ?messageThreadId: int64, ?googlePlaceType: string, ?replyMarkup: Markup) = + SendVenue.Make(ChatId.String chatId, latitude, longitude, title, address, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?allowPaidBroadcast = allowPaidBroadcast, ?protectContent = protectContent, ?disableNotification = disableNotification, ?foursquareType = foursquareType, ?googlePlaceId = googlePlaceId, ?replyParameters = replyParameters, ?foursquareId = foursquareId, ?messageThreadId = messageThreadId, ?googlePlaceType = googlePlaceType, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendVenue" @@ -695,11 +721,12 @@ type SendContact = Vcard: string option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, phoneNumber: string, firstName: string, ?businessConnectionId: string, ?messageThreadId: int64, ?lastName: string, ?vcard: string, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, phoneNumber: string, firstName: string, ?businessConnectionId: string, ?messageThreadId: int64, ?lastName: string, ?vcard: string, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -710,14 +737,15 @@ type SendContact = Vcard = vcard DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, phoneNumber: string, firstName: string, ?businessConnectionId: string, ?messageThreadId: int64, ?lastName: string, ?vcard: string, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendContact.Make(ChatId.Int chatId, phoneNumber, firstName, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?lastName = lastName, ?vcard = vcard, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) - static member Make(chatId: string, phoneNumber: string, firstName: string, ?businessConnectionId: string, ?messageThreadId: int64, ?lastName: string, ?vcard: string, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendContact.Make(ChatId.String chatId, phoneNumber, firstName, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?lastName = lastName, ?vcard = vcard, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, phoneNumber: string, firstName: string, ?businessConnectionId: string, ?messageThreadId: int64, ?lastName: string, ?vcard: string, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendContact.Make(ChatId.Int chatId, phoneNumber, firstName, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?lastName = lastName, ?vcard = vcard, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: string, phoneNumber: string, firstName: string, ?businessConnectionId: string, ?messageThreadId: int64, ?lastName: string, ?vcard: string, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendContact.Make(ChatId.String chatId, phoneNumber, firstName, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?lastName = lastName, ?vcard = vcard, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendContact" @@ -742,11 +770,12 @@ type SendPoll = IsClosed: bool option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, question: string, options: InputPollOption[], ?businessConnectionId: string, ?messageEffectId: string, ?protectContent: bool, ?disableNotification: bool, ?isClosed: bool, ?closeDate: int64, ?openPeriod: int64, ?explanationEntities: MessageEntity[], ?explanationParseMode: string, ?correctOptionId: int64, ?replyParameters: ReplyParameters, ?allowsMultipleAnswers: bool, ?``type``: string, ?isAnonymous: bool, ?questionEntities: MessageEntity[], ?questionParseMode: string, ?messageThreadId: int64, ?explanation: string, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, question: string, options: InputPollOption[], ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?isClosed: bool, ?closeDate: int64, ?openPeriod: int64, ?explanationEntities: MessageEntity[], ?explanation: string, ?replyParameters: ReplyParameters, ?correctOptionId: int64, ?allowsMultipleAnswers: bool, ?``type``: string, ?isAnonymous: bool, ?questionEntities: MessageEntity[], ?questionParseMode: string, ?messageThreadId: int64, ?explanationParseMode: string, ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -767,14 +796,15 @@ type SendPoll = IsClosed = isClosed DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, question: string, options: InputPollOption[], ?businessConnectionId: string, ?messageEffectId: string, ?protectContent: bool, ?disableNotification: bool, ?isClosed: bool, ?closeDate: int64, ?openPeriod: int64, ?explanationEntities: MessageEntity[], ?explanationParseMode: string, ?correctOptionId: int64, ?replyParameters: ReplyParameters, ?allowsMultipleAnswers: bool, ?``type``: string, ?isAnonymous: bool, ?questionEntities: MessageEntity[], ?questionParseMode: string, ?messageThreadId: int64, ?explanation: string, ?replyMarkup: Markup) = - SendPoll.Make(ChatId.Int chatId, question, options, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?protectContent = protectContent, ?disableNotification = disableNotification, ?isClosed = isClosed, ?closeDate = closeDate, ?openPeriod = openPeriod, ?explanationEntities = explanationEntities, ?explanationParseMode = explanationParseMode, ?correctOptionId = correctOptionId, ?replyParameters = replyParameters, ?allowsMultipleAnswers = allowsMultipleAnswers, ?``type`` = ``type``, ?isAnonymous = isAnonymous, ?questionEntities = questionEntities, ?questionParseMode = questionParseMode, ?messageThreadId = messageThreadId, ?explanation = explanation, ?replyMarkup = replyMarkup) - static member Make(chatId: string, question: string, options: InputPollOption[], ?businessConnectionId: string, ?messageEffectId: string, ?protectContent: bool, ?disableNotification: bool, ?isClosed: bool, ?closeDate: int64, ?openPeriod: int64, ?explanationEntities: MessageEntity[], ?explanationParseMode: string, ?correctOptionId: int64, ?replyParameters: ReplyParameters, ?allowsMultipleAnswers: bool, ?``type``: string, ?isAnonymous: bool, ?questionEntities: MessageEntity[], ?questionParseMode: string, ?messageThreadId: int64, ?explanation: string, ?replyMarkup: Markup) = - SendPoll.Make(ChatId.String chatId, question, options, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?protectContent = protectContent, ?disableNotification = disableNotification, ?isClosed = isClosed, ?closeDate = closeDate, ?openPeriod = openPeriod, ?explanationEntities = explanationEntities, ?explanationParseMode = explanationParseMode, ?correctOptionId = correctOptionId, ?replyParameters = replyParameters, ?allowsMultipleAnswers = allowsMultipleAnswers, ?``type`` = ``type``, ?isAnonymous = isAnonymous, ?questionEntities = questionEntities, ?questionParseMode = questionParseMode, ?messageThreadId = messageThreadId, ?explanation = explanation, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, question: string, options: InputPollOption[], ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?isClosed: bool, ?closeDate: int64, ?openPeriod: int64, ?explanationEntities: MessageEntity[], ?explanation: string, ?replyParameters: ReplyParameters, ?correctOptionId: int64, ?allowsMultipleAnswers: bool, ?``type``: string, ?isAnonymous: bool, ?questionEntities: MessageEntity[], ?questionParseMode: string, ?messageThreadId: int64, ?explanationParseMode: string, ?replyMarkup: Markup) = + SendPoll.Make(ChatId.Int chatId, question, options, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?allowPaidBroadcast = allowPaidBroadcast, ?protectContent = protectContent, ?disableNotification = disableNotification, ?isClosed = isClosed, ?closeDate = closeDate, ?openPeriod = openPeriod, ?explanationEntities = explanationEntities, ?explanation = explanation, ?replyParameters = replyParameters, ?correctOptionId = correctOptionId, ?allowsMultipleAnswers = allowsMultipleAnswers, ?``type`` = ``type``, ?isAnonymous = isAnonymous, ?questionEntities = questionEntities, ?questionParseMode = questionParseMode, ?messageThreadId = messageThreadId, ?explanationParseMode = explanationParseMode, ?replyMarkup = replyMarkup) + static member Make(chatId: string, question: string, options: InputPollOption[], ?businessConnectionId: string, ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?isClosed: bool, ?closeDate: int64, ?openPeriod: int64, ?explanationEntities: MessageEntity[], ?explanation: string, ?replyParameters: ReplyParameters, ?correctOptionId: int64, ?allowsMultipleAnswers: bool, ?``type``: string, ?isAnonymous: bool, ?questionEntities: MessageEntity[], ?questionParseMode: string, ?messageThreadId: int64, ?explanationParseMode: string, ?replyMarkup: Markup) = + SendPoll.Make(ChatId.String chatId, question, options, ?businessConnectionId = businessConnectionId, ?messageEffectId = messageEffectId, ?allowPaidBroadcast = allowPaidBroadcast, ?protectContent = protectContent, ?disableNotification = disableNotification, ?isClosed = isClosed, ?closeDate = closeDate, ?openPeriod = openPeriod, ?explanationEntities = explanationEntities, ?explanation = explanation, ?replyParameters = replyParameters, ?correctOptionId = correctOptionId, ?allowsMultipleAnswers = allowsMultipleAnswers, ?``type`` = ``type``, ?isAnonymous = isAnonymous, ?questionEntities = questionEntities, ?questionParseMode = questionParseMode, ?messageThreadId = messageThreadId, ?explanationParseMode = explanationParseMode, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendPoll" @@ -786,11 +816,12 @@ type SendDice = Emoji: string option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, ?businessConnectionId: string, ?messageThreadId: int64, ?emoji: string, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, ?businessConnectionId: string, ?messageThreadId: int64, ?emoji: string, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -798,14 +829,15 @@ type SendDice = Emoji = emoji DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, ?businessConnectionId: string, ?messageThreadId: int64, ?emoji: string, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendDice.Make(ChatId.Int chatId, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?emoji = emoji, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) - static member Make(chatId: string, ?businessConnectionId: string, ?messageThreadId: int64, ?emoji: string, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendDice.Make(ChatId.String chatId, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?emoji = emoji, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, ?businessConnectionId: string, ?messageThreadId: int64, ?emoji: string, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendDice.Make(ChatId.Int chatId, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?emoji = emoji, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: string, ?businessConnectionId: string, ?messageThreadId: int64, ?emoji: string, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendDice.Make(ChatId.String chatId, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?emoji = emoji, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendDice" @@ -866,6 +898,21 @@ type GetUserProfilePhotos = interface IRequestBase with member _.MethodName = "getUserProfilePhotos" +type SetUserEmojiStatus = + { + UserId: int64 + EmojiStatusCustomEmojiId: string option + EmojiStatusExpirationDate: int64 option + } + static member Make(userId: int64, ?emojiStatusCustomEmojiId: string, ?emojiStatusExpirationDate: int64) = + { + UserId = userId + EmojiStatusCustomEmojiId = emojiStatusCustomEmojiId + EmojiStatusExpirationDate = emojiStatusExpirationDate + } + interface IRequestBase with + member _.MethodName = "setUserEmojiStatus" + type GetFile = { FileId: string @@ -2066,11 +2113,12 @@ type SendSticker = Emoji: string option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: Markup option } - static member Make(chatId: ChatId, sticker: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?emoji: string, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + static member Make(chatId: ChatId, sticker: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?emoji: string, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -2079,14 +2127,15 @@ type SendSticker = Emoji = emoji DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, sticker: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?emoji: string, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendSticker.Make(ChatId.Int chatId, sticker, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?emoji = emoji, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) - static member Make(chatId: string, sticker: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?emoji: string, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = - SendSticker.Make(ChatId.String chatId, sticker, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?emoji = emoji, ?disableNotification = disableNotification, ?protectContent = protectContent, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, sticker: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?emoji: string, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendSticker.Make(ChatId.Int chatId, sticker, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?emoji = emoji, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) + static member Make(chatId: string, sticker: InputFile, ?businessConnectionId: string, ?messageThreadId: int64, ?emoji: string, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: Markup) = + SendSticker.Make(ChatId.String chatId, sticker, ?businessConnectionId = businessConnectionId, ?messageThreadId = messageThreadId, ?emoji = emoji, ?disableNotification = disableNotification, ?protectContent = protectContent, ?allowPaidBroadcast = allowPaidBroadcast, ?messageEffectId = messageEffectId, ?replyParameters = replyParameters, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendSticker" @@ -2297,6 +2346,88 @@ type DeleteStickerSet = interface IRequestBase with member _.MethodName = "deleteStickerSet" +type GetAvailableGifts() = + static member Make() = GetAvailableGifts() + interface IRequestBase with + member _.MethodName = "getAvailableGifts" + +type SendGift = + { + UserId: int64 + GiftId: string + PayForUpgrade: bool option + Text: string option + TextParseMode: string option + TextEntities: MessageEntity[] option + } + static member Make(userId: int64, giftId: string, ?payForUpgrade: bool, ?text: string, ?textParseMode: string, ?textEntities: MessageEntity[]) = + { + UserId = userId + GiftId = giftId + PayForUpgrade = payForUpgrade + Text = text + TextParseMode = textParseMode + TextEntities = textEntities + } + interface IRequestBase with + member _.MethodName = "sendGift" + +type VerifyUser = + { + UserId: int64 + CustomDescription: string option + } + static member Make(userId: int64, ?customDescription: string) = + { + UserId = userId + CustomDescription = customDescription + } + interface IRequestBase with + member _.MethodName = "verifyUser" + +type VerifyChat = + { + ChatId: ChatId + CustomDescription: string option + } + static member Make(chatId: ChatId, ?customDescription: string) = + { + ChatId = chatId + CustomDescription = customDescription + } + static member Make(chatId: int64, ?customDescription: string) = + VerifyChat.Make(ChatId.Int chatId, ?customDescription = customDescription) + static member Make(chatId: string, ?customDescription: string) = + VerifyChat.Make(ChatId.String chatId, ?customDescription = customDescription) + interface IRequestBase with + member _.MethodName = "verifyChat" + +type RemoveUserVerification = + { + UserId: int64 + } + static member Make(userId: int64) = + { + UserId = userId + } + interface IRequestBase with + member _.MethodName = "removeUserVerification" + +type RemoveChatVerification = + { + ChatId: ChatId + } + static member Make(chatId: ChatId) = + { + ChatId = chatId + } + static member Make(chatId: int64) = + RemoveChatVerification.Make(ChatId.Int chatId) + static member Make(chatId: string) = + RemoveChatVerification.Make(ChatId.String chatId) + interface IRequestBase with + member _.MethodName = "removeChatVerification" + type AnswerInlineQuery = { InlineQueryId: string @@ -2331,6 +2462,27 @@ type AnswerWebAppQuery = interface IRequestBase with member _.MethodName = "answerWebAppQuery" +type SavePreparedInlineMessage = + { + UserId: int64 + Result: InlineQueryResult + AllowUserChats: bool option + AllowBotChats: bool option + AllowGroupChats: bool option + AllowChannelChats: bool option + } + static member Make(userId: int64, result: InlineQueryResult, ?allowUserChats: bool, ?allowBotChats: bool, ?allowGroupChats: bool, ?allowChannelChats: bool) = + { + UserId = userId + Result = result + AllowUserChats = allowUserChats + AllowBotChats = allowBotChats + AllowGroupChats = allowGroupChats + AllowChannelChats = allowChannelChats + } + interface IRequestBase with + member _.MethodName = "savePreparedInlineMessage" + type SendInvoice = { ChatId: ChatId @@ -2358,11 +2510,12 @@ type SendInvoice = IsFlexible: bool option DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: InlineKeyboardMarkup option } - static member Make(chatId: ChatId, title: string, description: string, payload: string, currency: string, prices: LabeledPrice[], ?messageEffectId: string, ?protectContent: bool, ?disableNotification: bool, ?isFlexible: bool, ?sendEmailToProvider: bool, ?sendPhoneNumberToProvider: bool, ?needShippingAddress: bool, ?needEmail: bool, ?needPhoneNumber: bool, ?needName: bool, ?photoSize: int64, ?photoWidth: int64, ?replyParameters: ReplyParameters, ?photoUrl: string, ?providerData: string, ?startParameter: string, ?suggestedTipAmounts: int64[], ?maxTipAmount: int64, ?providerToken: string, ?messageThreadId: int64, ?photoHeight: int64, ?replyMarkup: InlineKeyboardMarkup) = + static member Make(chatId: ChatId, title: string, description: string, payload: string, currency: string, prices: LabeledPrice[], ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?isFlexible: bool, ?sendEmailToProvider: bool, ?sendPhoneNumberToProvider: bool, ?needShippingAddress: bool, ?needEmail: bool, ?needPhoneNumber: bool, ?photoWidth: int64, ?photoHeight: int64, ?replyParameters: ReplyParameters, ?photoSize: int64, ?photoUrl: string, ?providerData: string, ?startParameter: string, ?suggestedTipAmounts: int64[], ?maxTipAmount: int64, ?providerToken: string, ?messageThreadId: int64, ?needName: bool, ?replyMarkup: InlineKeyboardMarkup) = { ChatId = chatId MessageThreadId = messageThreadId @@ -2389,25 +2542,28 @@ type SendInvoice = IsFlexible = isFlexible DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup } - static member Make(chatId: int64, title: string, description: string, payload: string, currency: string, prices: LabeledPrice[], ?messageEffectId: string, ?protectContent: bool, ?disableNotification: bool, ?isFlexible: bool, ?sendEmailToProvider: bool, ?sendPhoneNumberToProvider: bool, ?needShippingAddress: bool, ?needEmail: bool, ?needPhoneNumber: bool, ?needName: bool, ?photoSize: int64, ?photoWidth: int64, ?replyParameters: ReplyParameters, ?photoUrl: string, ?providerData: string, ?startParameter: string, ?suggestedTipAmounts: int64[], ?maxTipAmount: int64, ?providerToken: string, ?messageThreadId: int64, ?photoHeight: int64, ?replyMarkup: InlineKeyboardMarkup) = - SendInvoice.Make(ChatId.Int chatId, title, description, payload, currency, prices, ?messageEffectId = messageEffectId, ?protectContent = protectContent, ?disableNotification = disableNotification, ?isFlexible = isFlexible, ?sendEmailToProvider = sendEmailToProvider, ?sendPhoneNumberToProvider = sendPhoneNumberToProvider, ?needShippingAddress = needShippingAddress, ?needEmail = needEmail, ?needPhoneNumber = needPhoneNumber, ?needName = needName, ?photoSize = photoSize, ?photoWidth = photoWidth, ?replyParameters = replyParameters, ?photoUrl = photoUrl, ?providerData = providerData, ?startParameter = startParameter, ?suggestedTipAmounts = suggestedTipAmounts, ?maxTipAmount = maxTipAmount, ?providerToken = providerToken, ?messageThreadId = messageThreadId, ?photoHeight = photoHeight, ?replyMarkup = replyMarkup) - static member Make(chatId: string, title: string, description: string, payload: string, currency: string, prices: LabeledPrice[], ?messageEffectId: string, ?protectContent: bool, ?disableNotification: bool, ?isFlexible: bool, ?sendEmailToProvider: bool, ?sendPhoneNumberToProvider: bool, ?needShippingAddress: bool, ?needEmail: bool, ?needPhoneNumber: bool, ?needName: bool, ?photoSize: int64, ?photoWidth: int64, ?replyParameters: ReplyParameters, ?photoUrl: string, ?providerData: string, ?startParameter: string, ?suggestedTipAmounts: int64[], ?maxTipAmount: int64, ?providerToken: string, ?messageThreadId: int64, ?photoHeight: int64, ?replyMarkup: InlineKeyboardMarkup) = - SendInvoice.Make(ChatId.String chatId, title, description, payload, currency, prices, ?messageEffectId = messageEffectId, ?protectContent = protectContent, ?disableNotification = disableNotification, ?isFlexible = isFlexible, ?sendEmailToProvider = sendEmailToProvider, ?sendPhoneNumberToProvider = sendPhoneNumberToProvider, ?needShippingAddress = needShippingAddress, ?needEmail = needEmail, ?needPhoneNumber = needPhoneNumber, ?needName = needName, ?photoSize = photoSize, ?photoWidth = photoWidth, ?replyParameters = replyParameters, ?photoUrl = photoUrl, ?providerData = providerData, ?startParameter = startParameter, ?suggestedTipAmounts = suggestedTipAmounts, ?maxTipAmount = maxTipAmount, ?providerToken = providerToken, ?messageThreadId = messageThreadId, ?photoHeight = photoHeight, ?replyMarkup = replyMarkup) + static member Make(chatId: int64, title: string, description: string, payload: string, currency: string, prices: LabeledPrice[], ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?isFlexible: bool, ?sendEmailToProvider: bool, ?sendPhoneNumberToProvider: bool, ?needShippingAddress: bool, ?needEmail: bool, ?needPhoneNumber: bool, ?photoWidth: int64, ?photoHeight: int64, ?replyParameters: ReplyParameters, ?photoSize: int64, ?photoUrl: string, ?providerData: string, ?startParameter: string, ?suggestedTipAmounts: int64[], ?maxTipAmount: int64, ?providerToken: string, ?messageThreadId: int64, ?needName: bool, ?replyMarkup: InlineKeyboardMarkup) = + SendInvoice.Make(ChatId.Int chatId, title, description, payload, currency, prices, ?messageEffectId = messageEffectId, ?allowPaidBroadcast = allowPaidBroadcast, ?protectContent = protectContent, ?disableNotification = disableNotification, ?isFlexible = isFlexible, ?sendEmailToProvider = sendEmailToProvider, ?sendPhoneNumberToProvider = sendPhoneNumberToProvider, ?needShippingAddress = needShippingAddress, ?needEmail = needEmail, ?needPhoneNumber = needPhoneNumber, ?photoWidth = photoWidth, ?photoHeight = photoHeight, ?replyParameters = replyParameters, ?photoSize = photoSize, ?photoUrl = photoUrl, ?providerData = providerData, ?startParameter = startParameter, ?suggestedTipAmounts = suggestedTipAmounts, ?maxTipAmount = maxTipAmount, ?providerToken = providerToken, ?messageThreadId = messageThreadId, ?needName = needName, ?replyMarkup = replyMarkup) + static member Make(chatId: string, title: string, description: string, payload: string, currency: string, prices: LabeledPrice[], ?messageEffectId: string, ?allowPaidBroadcast: bool, ?protectContent: bool, ?disableNotification: bool, ?isFlexible: bool, ?sendEmailToProvider: bool, ?sendPhoneNumberToProvider: bool, ?needShippingAddress: bool, ?needEmail: bool, ?needPhoneNumber: bool, ?photoWidth: int64, ?photoHeight: int64, ?replyParameters: ReplyParameters, ?photoSize: int64, ?photoUrl: string, ?providerData: string, ?startParameter: string, ?suggestedTipAmounts: int64[], ?maxTipAmount: int64, ?providerToken: string, ?messageThreadId: int64, ?needName: bool, ?replyMarkup: InlineKeyboardMarkup) = + SendInvoice.Make(ChatId.String chatId, title, description, payload, currency, prices, ?messageEffectId = messageEffectId, ?allowPaidBroadcast = allowPaidBroadcast, ?protectContent = protectContent, ?disableNotification = disableNotification, ?isFlexible = isFlexible, ?sendEmailToProvider = sendEmailToProvider, ?sendPhoneNumberToProvider = sendPhoneNumberToProvider, ?needShippingAddress = needShippingAddress, ?needEmail = needEmail, ?needPhoneNumber = needPhoneNumber, ?photoWidth = photoWidth, ?photoHeight = photoHeight, ?replyParameters = replyParameters, ?photoSize = photoSize, ?photoUrl = photoUrl, ?providerData = providerData, ?startParameter = startParameter, ?suggestedTipAmounts = suggestedTipAmounts, ?maxTipAmount = maxTipAmount, ?providerToken = providerToken, ?messageThreadId = messageThreadId, ?needName = needName, ?replyMarkup = replyMarkup) interface IRequestBase with member _.MethodName = "sendInvoice" type CreateInvoiceLink = { + BusinessConnectionId: string option Title: string Description: string Payload: string ProviderToken: string option Currency: string Prices: LabeledPrice[] + SubscriptionPeriod: int64 option MaxTipAmount: int64 option SuggestedTipAmounts: int64[] option ProviderData: string option @@ -2423,14 +2579,16 @@ type CreateInvoiceLink = SendEmailToProvider: bool option IsFlexible: bool option } - static member Make(title: string, description: string, payload: string, currency: string, prices: LabeledPrice[], ?sendPhoneNumberToProvider: bool, ?needShippingAddress: bool, ?needEmail: bool, ?needPhoneNumber: bool, ?needName: bool, ?photoHeight: int64, ?photoUrl: string, ?photoSize: int64, ?sendEmailToProvider: bool, ?providerData: string, ?suggestedTipAmounts: int64[], ?maxTipAmount: int64, ?providerToken: string, ?photoWidth: int64, ?isFlexible: bool) = + static member Make(title: string, description: string, payload: string, currency: string, prices: LabeledPrice[], ?businessConnectionId: string, ?sendPhoneNumberToProvider: bool, ?needShippingAddress: bool, ?needEmail: bool, ?needPhoneNumber: bool, ?needName: bool, ?photoHeight: int64, ?photoWidth: int64, ?providerData: string, ?photoUrl: string, ?sendEmailToProvider: bool, ?suggestedTipAmounts: int64[], ?maxTipAmount: int64, ?subscriptionPeriod: int64, ?providerToken: string, ?photoSize: int64, ?isFlexible: bool) = { + BusinessConnectionId = businessConnectionId Title = title Description = description Payload = payload ProviderToken = providerToken Currency = currency Prices = prices + SubscriptionPeriod = subscriptionPeriod MaxTipAmount = maxTipAmount SuggestedTipAmounts = suggestedTipAmounts ProviderData = providerData @@ -2507,6 +2665,21 @@ type RefundStarPayment = interface IRequestBase with member _.MethodName = "refundStarPayment" +type EditUserStarSubscription = + { + UserId: int64 + TelegramPaymentChargeId: string + IsCanceled: bool + } + static member Make(userId: int64, telegramPaymentChargeId: string, isCanceled: bool) = + { + UserId = userId + TelegramPaymentChargeId = telegramPaymentChargeId + IsCanceled = isCanceled + } + interface IRequestBase with + member _.MethodName = "editUserStarSubscription" + type SetPassportDataErrors = { UserId: int64 @@ -2528,11 +2701,12 @@ type SendGame = GameShortName: string DisableNotification: bool option ProtectContent: bool option + AllowPaidBroadcast: bool option MessageEffectId: string option ReplyParameters: ReplyParameters option ReplyMarkup: InlineKeyboardMarkup option } - static member Make(chatId: int64, gameShortName: string, ?businessConnectionId: string, ?messageThreadId: int64, ?disableNotification: bool, ?protectContent: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: InlineKeyboardMarkup) = + static member Make(chatId: int64, gameShortName: string, ?businessConnectionId: string, ?messageThreadId: int64, ?disableNotification: bool, ?protectContent: bool, ?allowPaidBroadcast: bool, ?messageEffectId: string, ?replyParameters: ReplyParameters, ?replyMarkup: InlineKeyboardMarkup) = { BusinessConnectionId = businessConnectionId ChatId = chatId @@ -2540,6 +2714,7 @@ type SendGame = GameShortName = gameShortName DisableNotification = disableNotification ProtectContent = protectContent + AllowPaidBroadcast = allowPaidBroadcast MessageEffectId = messageEffectId ReplyParameters = replyParameters ReplyMarkup = replyMarkup diff --git a/src/Funogram.Telegram/Types.fs b/src/Funogram.Telegram/Types.fs index 9d3f395..d244cd7 100644 --- a/src/Funogram.Telegram/Types.fs +++ b/src/Funogram.Telegram/Types.fs @@ -507,7 +507,7 @@ and [] ChatFullInfo = /// This object represents a message. and [] Message = { - /// Unique message identifier inside this chat + /// Unique message identifier inside this chat. In specific instances (e.g., message containing a video sent to a big chat), the server might automatically schedule a message instead of sending it immediately. In such cases, this field will be 0 and the relevant message will be unusable until it is actually sent [] MessageId: int64 /// Unique identifier of a message thread to which the message belongs; for supergroups only @@ -855,7 +855,7 @@ and [] Message = /// This object represents a unique message identifier. and [] MessageId = { - /// Unique message identifier + /// Unique message identifier. In specific instances (e.g., message containing a video sent to a big chat), the server might automatically schedule a message instead of sending it immediately. In such cases, this field will be 0 and the relevant message will be unusable until it is actually sent [] MessageId: int64 } @@ -892,7 +892,7 @@ and MaybeInaccessibleMessage = /// This object represents one special entity in a text message. For example, hashtags, usernames, URLs, etc. and [] MessageEntity = { - /// Type of the entity. Currently, can be “mention” (@username), “hashtag” (#hashtag), “cashtag” ($USD), “bot_command” (/start@jobs_bot), “url” (https://telegram.org), “email” (do-not-reply@telegram.org), “phone_number” (+1-212-555-0123), “bold” (bold text), “italic” (italic text), “underline” (underlined text), “strikethrough” (strikethrough text), “spoiler” (spoiler message), “blockquote” (block quotation), “expandable_blockquote” (collapsed-by-default block quotation), “code” (monowidth string), “pre” (monowidth block), “text_link” (for clickable text URLs), “text_mention” (for users without usernames), “custom_emoji” (for inline custom emoji stickers) + /// Type of the entity. Currently, can be “mention” (@username), “hashtag” (#hashtag or #hashtag@chatusername), “cashtag” ($USD or $USD@chatusername), “bot_command” (/start@jobs_bot), “url” (https://telegram.org), “email” (do-not-reply@telegram.org), “phone_number” (+1-212-555-0123), “bold” (bold text), “italic” (italic text), “underline” (underlined text), “strikethrough” (strikethrough text), “spoiler” (spoiler message), “blockquote” (block quotation), “expandable_blockquote” (collapsed-by-default block quotation), “code” (monowidth string), “pre” (monowidth block), “text_link” (for clickable text URLs), “text_mention” (for users without usernames), “custom_emoji” (for inline custom emoji stickers) [] Type: string /// Offset in UTF-16 code units to the start of the entity @@ -1951,7 +1951,7 @@ and [] BackgroundTypeWallpaper = IsMoving = isMoving } -/// The background is a PNG or TGV (gzipped subset of SVG with MIME type “application/x-tgwallpattern”) pattern to be combined with the background fill chosen by the user. +/// The background is a .PNG or .TGV (gzipped subset of SVG with MIME type “application/x-tgwallpattern”) pattern to be combined with the background fill chosen by the user. and [] BackgroundTypePattern = { /// Type of the background, always “pattern” @@ -2653,6 +2653,9 @@ and [] InlineKeyboardButton = /// If set, pressing the button will prompt the user to select one of their chats of the specified type, open that chat and insert the bot's username and the specified inline query in the input field. Not supported for messages sent on behalf of a Telegram Business account. [] SwitchInlineQueryChosenChat: SwitchInlineQueryChosenChat option + /// Description of the button that copies the specified text to the clipboard. + [] + CopyText: CopyTextButton option /// Description of the game that will be launched when the user presses the button. /// /// NOTE: This type of button must always be the first button in the first row. @@ -2664,7 +2667,7 @@ and [] InlineKeyboardButton = [] Pay: bool option } - static member Create(text: string, ?url: string, ?callbackData: string, ?webApp: WebAppInfo, ?loginUrl: LoginUrl, ?switchInlineQuery: string, ?switchInlineQueryCurrentChat: string, ?switchInlineQueryChosenChat: SwitchInlineQueryChosenChat, ?callbackGame: CallbackGame, ?pay: bool) = + static member Create(text: string, ?url: string, ?callbackData: string, ?webApp: WebAppInfo, ?loginUrl: LoginUrl, ?switchInlineQuery: string, ?switchInlineQueryCurrentChat: string, ?switchInlineQueryChosenChat: SwitchInlineQueryChosenChat, ?copyText: CopyTextButton, ?callbackGame: CallbackGame, ?pay: bool) = { Text = text Url = url @@ -2674,6 +2677,7 @@ and [] InlineKeyboardButton = SwitchInlineQuery = switchInlineQuery SwitchInlineQueryCurrentChat = switchInlineQueryCurrentChat SwitchInlineQueryChosenChat = switchInlineQueryChosenChat + CopyText = copyText CallbackGame = callbackGame Pay = pay } @@ -2733,6 +2737,18 @@ and [] SwitchInlineQueryChosenChat = AllowChannelChats = allowChannelChats } +/// This object represents an inline keyboard button that copies specified text to the clipboard. +and [] CopyTextButton = + { + /// The text to be copied to the clipboard; 1-256 characters + [] + Text: string + } + static member Create(text: string) = + { + Text = text + } + /// This object represents an incoming callback query from a callback button in an inline keyboard. If the button that originated the query was attached to a message sent by the bot, the field message will be present. If the button was attached to a message sent via the bot (in inline mode), the field inline_message_id will be present. Exactly one of the fields data or game_short_name will be present. and [] CallbackQuery = { @@ -4422,7 +4438,7 @@ and [] InputSticker = /// The added sticker. Pass a file_id as a String to send a file that already exists on the Telegram servers, pass an HTTP URL as a String for Telegram to get a file from the Internet, upload a new one using multipart/form-data, or pass “attach://” to upload a new one using multipart/form-data under name. Animated and video stickers can't be uploaded via HTTP URL. More information on Sending Files » [] Sticker: InputFile - /// Format of the added sticker, must be one of “static” for a .WEBP or .PNG image, “animated” for a .TGS animation, “video” for a WEBM video + /// Format of the added sticker, must be one of “static” for a .WEBP or .PNG image, “animated” for a .TGS animation, “video” for a .WEBM video [] Format: string /// List of 1-20 emoji associated with the sticker @@ -4444,6 +4460,50 @@ and [] InputSticker = Keywords = keywords } +/// This object represents a gift that can be sent by the bot. +and [] Gift = + { + /// Unique identifier of the gift + [] + Id: string + /// The sticker that represents the gift + [] + Sticker: Sticker + /// The number of Telegram Stars that must be paid to send the sticker + [] + StarCount: int64 + /// The number of Telegram Stars that must be paid to upgrade the gift to a unique one + [] + UpgradeStarCount: int64 option + /// The total number of the gifts of this type that can be sent; for limited gifts only + [] + TotalCount: int64 option + /// The number of remaining gifts of this type that can be sent; for limited gifts only + [] + RemainingCount: int64 option + } + static member Create(id: string, sticker: Sticker, starCount: int64, ?upgradeStarCount: int64, ?totalCount: int64, ?remainingCount: int64) = + { + Id = id + Sticker = sticker + StarCount = starCount + UpgradeStarCount = upgradeStarCount + TotalCount = totalCount + RemainingCount = remainingCount + } + +/// This object represent a list of gifts. +and [] Gifts = + { + /// The list of gifts + [] + Gifts: Gift[] + } + static member Create(gifts: Gift[]) = + { + Gifts = gifts + } + /// This object represents an incoming inline query. When the user sends an empty query, your bot could return some default or trending results. and [] InlineQuery = { @@ -4543,9 +4603,6 @@ and [] InlineQueryResultArticle = /// URL of the result [] Url: string option - /// Pass True if you don't want the URL to be shown in the message - [] - HideUrl: bool option /// Short description of the result [] Description: string option @@ -4559,7 +4616,7 @@ and [] InlineQueryResultArticle = [] ThumbnailHeight: int64 option } - static member Create(``type``: string, id: string, title: string, inputMessageContent: InputMessageContent, ?replyMarkup: InlineKeyboardMarkup, ?url: string, ?hideUrl: bool, ?description: string, ?thumbnailUrl: string, ?thumbnailWidth: int64, ?thumbnailHeight: int64) = + static member Create(``type``: string, id: string, title: string, inputMessageContent: InputMessageContent, ?replyMarkup: InlineKeyboardMarkup, ?url: string, ?description: string, ?thumbnailUrl: string, ?thumbnailWidth: int64, ?thumbnailHeight: int64) = { Type = ``type`` Id = id @@ -4567,7 +4624,6 @@ and [] InlineQueryResultArticle = InputMessageContent = inputMessageContent ReplyMarkup = replyMarkup Url = url - HideUrl = hideUrl Description = description ThumbnailUrl = thumbnailUrl ThumbnailWidth = thumbnailWidth @@ -4647,7 +4703,7 @@ and [] InlineQueryResultGif = /// Unique identifier for this result, 1-64 bytes [] Id: string - /// A valid URL for the GIF file. File size must not exceed 1MB + /// A valid URL for the GIF file [] GifUrl: string /// Width of the GIF @@ -4715,7 +4771,7 @@ and [] InlineQueryResultMpeg4Gif = /// Unique identifier for this result, 1-64 bytes [] Id: string - /// A valid URL for the MPEG4 file. File size must not exceed 1MB + /// A valid URL for the MPEG4 file [] Mpeg4Url: string /// Video width @@ -5824,7 +5880,6 @@ and [] ChosenInlineResult = } /// Describes an inline message sent by a Web App on behalf of a user. -/// Your bot can accept payments from Telegram users. Please see the introduction to payments for more details on the process and how to set up payments for your bot. and [] SentWebAppMessage = { /// Identifier of the sent inline message. Available only if there is an inline keyboard attached to the message. @@ -5836,6 +5891,23 @@ and [] SentWebAppMessage = InlineMessageId = inlineMessageId } +/// Describes an inline message to be sent by a user of a Mini App. +/// Your bot can accept payments from Telegram users. Please see the introduction to payments for more details on the process and how to set up payments for your bot. +and [] PreparedInlineMessage = + { + /// Unique identifier of the prepared message + [] + Id: string + /// Expiration date of the prepared message, in Unix time. Expired prepared messages can no longer be used + [] + ExpirationDate: int64 + } + static member Create(id: string, expirationDate: int64) = + { + Id = id + ExpirationDate = expirationDate + } + /// This object represents a portion of the price for goods or services. and [] LabeledPrice = { @@ -5956,7 +6028,7 @@ and [] ShippingOption = Prices = prices } -/// This object contains basic information about a successful payment. +/// This object contains basic information about a successful payment. Note that if the buyer initiates a chargeback with the relevant payment provider following this transaction, the funds may be debited from your balance. This is outside of Telegram's control. and [] SuccessfulPayment = { /// Three-letter ISO 4217 currency code, or “XTR” for payments in Telegram Stars @@ -5968,6 +6040,15 @@ and [] SuccessfulPayment = /// Bot-specified invoice payload [] InvoicePayload: string + /// Expiration date of the subscription, in Unix time; for recurring payments only + [] + SubscriptionExpirationDate: int64 option + /// True, if the payment is a recurring payment for a subscription + [] + IsRecurring: bool option + /// True, if the payment is the first payment for a subscription + [] + IsFirstRecurring: bool option /// Identifier of the shipping option chosen by the user [] ShippingOptionId: string option @@ -5981,13 +6062,16 @@ and [] SuccessfulPayment = [] ProviderPaymentChargeId: string } - static member Create(currency: string, totalAmount: int64, invoicePayload: string, telegramPaymentChargeId: string, providerPaymentChargeId: string, ?shippingOptionId: string, ?orderInfo: OrderInfo) = + static member Create(currency: string, totalAmount: int64, invoicePayload: string, telegramPaymentChargeId: string, providerPaymentChargeId: string, ?subscriptionExpirationDate: int64, ?isRecurring: bool, ?isFirstRecurring: bool, ?shippingOptionId: string, ?orderInfo: OrderInfo) = { Currency = currency TotalAmount = totalAmount InvoicePayload = invoicePayload TelegramPaymentChargeId = telegramPaymentChargeId ProviderPaymentChargeId = providerPaymentChargeId + SubscriptionExpirationDate = subscriptionExpirationDate + IsRecurring = isRecurring + IsFirstRecurring = isFirstRecurring ShippingOptionId = shippingOptionId OrderInfo = orderInfo } @@ -6146,11 +6230,41 @@ and [] RevenueWithdrawalStateFailed = Type = ``type`` } +/// Contains information about the affiliate that received a commission via this transaction. +and [] AffiliateInfo = + { + /// The bot or the user that received an affiliate commission if it was received by a bot or a user + [] + AffiliateUser: User option + /// The chat that received an affiliate commission if it was received by a chat + [] + AffiliateChat: Chat option + /// The number of Telegram Stars received by the affiliate for each 1000 Telegram Stars received by the bot from referred users + [] + CommissionPerMille: int64 + /// Integer amount of Telegram Stars received by the affiliate from the transaction, rounded to 0; can be negative for refunds + [] + Amount: int64 + /// The number of 1/1000000000 shares of Telegram Stars received by the affiliate; from -999999999 to 999999999; can be negative for refunds + [] + NanostarAmount: int64 option + } + static member Create(commissionPerMille: int64, amount: int64, ?affiliateUser: User, ?affiliateChat: Chat, ?nanostarAmount: int64) = + { + CommissionPerMille = commissionPerMille + Amount = amount + AffiliateUser = affiliateUser + AffiliateChat = affiliateChat + NanostarAmount = nanostarAmount + } + /// This object describes the source of a transaction, or its recipient for outgoing transactions. Currently, it can be one of and TransactionPartner = | User of TransactionPartnerUser + | AffiliateProgram of TransactionPartnerAffiliateProgram | Fragment of TransactionPartnerFragment | TelegramAds of TransactionPartnerTelegramAds + | TelegramApi of TransactionPartnerTelegramApi | Other of TransactionPartnerOther /// Describes a transaction with a user. @@ -6162,23 +6276,55 @@ and [] TransactionPartnerUser = /// Information about the user [] User: User + /// Information about the affiliate that received a commission via this transaction + [] + Affiliate: AffiliateInfo option /// Bot-specified invoice payload [] InvoicePayload: string option + /// The duration of the paid subscription + [] + SubscriptionPeriod: int64 option /// Information about the paid media bought by the user [] PaidMedia: PaidMedia[] option /// Bot-specified paid media payload [] PaidMediaPayload: string option + /// The gift sent to the user by the bot + [] + Gift: Gift option } - static member Create(``type``: string, user: User, ?invoicePayload: string, ?paidMedia: PaidMedia[], ?paidMediaPayload: string) = + static member Create(``type``: string, user: User, ?affiliate: AffiliateInfo, ?invoicePayload: string, ?subscriptionPeriod: int64, ?paidMedia: PaidMedia[], ?paidMediaPayload: string, ?gift: Gift) = { Type = ``type`` User = user + Affiliate = affiliate InvoicePayload = invoicePayload + SubscriptionPeriod = subscriptionPeriod PaidMedia = paidMedia PaidMediaPayload = paidMediaPayload + Gift = gift + } + +/// Describes the affiliate program that issued the affiliate commission received via this transaction. +and [] TransactionPartnerAffiliateProgram = + { + /// Type of the transaction partner, always “affiliate_program” + [] + Type: string + /// Information about the bot that sponsored the affiliate program + [] + SponsorUser: User option + /// The number of Telegram Stars received by the bot for each 1000 Telegram Stars received by the affiliate program sponsor from referred users + [] + CommissionPerMille: int64 + } + static member Create(``type``: string, commissionPerMille: int64, ?sponsorUser: User) = + { + Type = ``type`` + CommissionPerMille = commissionPerMille + SponsorUser = sponsorUser } /// Describes a withdrawal transaction with Fragment. @@ -6209,6 +6355,22 @@ and [] TransactionPartnerTelegramAds = Type = ``type`` } +/// Describes a transaction with payment for paid broadcasting. +and [] TransactionPartnerTelegramApi = + { + /// Type of the transaction partner, always “telegram_api” + [] + Type: string + /// The number of successful requests that exceeded regular limits and were therefore billed + [] + RequestCount: int64 + } + static member Create(``type``: string, requestCount: int64) = + { + Type = ``type`` + RequestCount = requestCount + } + /// Describes a transaction with an unknown source or recipient. and [] TransactionPartnerOther = { @@ -6221,15 +6383,18 @@ and [] TransactionPartnerOther = Type = ``type`` } -/// Describes a Telegram Star transaction. +/// Describes a Telegram Star transaction. Note that if the buyer initiates a chargeback with the payment provider from whom they acquired Stars (e.g., Apple, Google) following this transaction, the refunded Stars will be deducted from the bot's balance. This is outside of Telegram's control. and [] StarTransaction = { - /// Unique identifier of the transaction. Coincides with the identifer of the original transaction for refund transactions. Coincides with SuccessfulPayment.telegram_payment_charge_id for successful incoming payments from users. + /// Unique identifier of the transaction. Coincides with the identifier of the original transaction for refund transactions. Coincides with SuccessfulPayment.telegram_payment_charge_id for successful incoming payments from users. [] Id: string - /// Number of Telegram Stars transferred by the transaction + /// Integer amount of Telegram Stars transferred by the transaction [] Amount: int64 + /// The number of 1/1000000000 shares of Telegram Stars transferred by the transaction; from 0 to 999999999 + [] + NanostarAmount: int64 option /// Date the transaction was created in Unix time [] Date: DateTime @@ -6240,11 +6405,12 @@ and [] StarTransaction = [] Receiver: TransactionPartner option } - static member Create(id: string, amount: int64, date: DateTime, ?source: TransactionPartner, ?receiver: TransactionPartner) = + static member Create(id: string, amount: int64, date: DateTime, ?nanostarAmount: int64, ?source: TransactionPartner, ?receiver: TransactionPartner) = { Id = id Amount = amount Date = date + NanostarAmount = nanostarAmount Source = source Receiver = receiver }