@grom.js/bot-api-spec 0.3.1 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/index.d.ts +4 -4
- package/dist/index.js +34 -34
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -25,7 +25,7 @@ Below are the rules how we map type of a field/parameter to the `ValueType`:
|
|
|
25
25
|
|
|
26
26
|
- _Type_ is _String_ — `{ type: 'str' }`
|
|
27
27
|
- _Type_ is _Integer_ — `{ type: 'int32' }`
|
|
28
|
-
- _Type_ is _Integer_ and _Description_ says "...may have more than 32 significant bits...but it has at most 52 significant bits..." — `{ type: '
|
|
28
|
+
- _Type_ is _Integer_ and _Description_ says "...may have more than 32 significant bits...but it has at most 52 significant bits..." — `{ type: 'int53' }`
|
|
29
29
|
- _Type_ is _Boolean_ — `{ type: 'bool' }`
|
|
30
30
|
- _Type_ is _True_ — `{ type: 'bool', literal: true }`
|
|
31
31
|
- _Type_ is _Float_ — `{ type: 'float' }`
|
|
@@ -41,4 +41,4 @@ Objects also include descriptions of the API types, methods, fields, and paramet
|
|
|
41
41
|
- Description is an object with a single `markdown` property, a string containing the description in Markdown format with formatting (**bold**, _italic_, etc.) and links preserved.
|
|
42
42
|
- "_Optional._" prefix in field descriptions is omitted; instead, the `required` property is set to `false` for such fields.
|
|
43
43
|
- "JSON-serialized..." in field/parameter descriptions is omitted; instead, the `jsonSerialized` property is set to `true` for such fields/parameters.
|
|
44
|
-
- "...may have more than 32 significant bits...but it has at most 52 significant bits..." in _Integer_ field/parameter descriptions is omitted; instead, `type` is set to `
|
|
44
|
+
- "...may have more than 32 significant bits...but it has at most 52 significant bits..." in _Integer_ field/parameter descriptions is omitted; instead, `type` is set to `int53` for such fields/parameters (as per [TDLib](https://core.telegram.org/tdlib/docs/td__api_8h.html#a6f57ab89c6371535f0fb7fec2d770126)).
|
package/dist/index.d.ts
CHANGED
|
@@ -83,7 +83,7 @@ interface Description {
|
|
|
83
83
|
/**
|
|
84
84
|
* Type of a value.
|
|
85
85
|
*/
|
|
86
|
-
type ValueType = ValueTypeString | ValueTypeBoolean | ValueTypeInteger32 |
|
|
86
|
+
type ValueType = ValueTypeString | ValueTypeBoolean | ValueTypeInteger32 | ValueTypeInteger53 | ValueTypeFloat | ValueTypeInputFile | ValueTypeApiType | ValueTypeArray | ValueTypeUnion;
|
|
87
87
|
/**
|
|
88
88
|
* `String` value type.
|
|
89
89
|
*/
|
|
@@ -110,8 +110,8 @@ interface ValueTypeInteger32 {
|
|
|
110
110
|
* at most 52 significant bits, so a 64-bit integer or double-precision float
|
|
111
111
|
* type are safe for storing values of this type.
|
|
112
112
|
*/
|
|
113
|
-
interface
|
|
114
|
-
type: '
|
|
113
|
+
interface ValueTypeInteger53 {
|
|
114
|
+
type: 'int53';
|
|
115
115
|
}
|
|
116
116
|
/**
|
|
117
117
|
* `Float` value type.
|
|
@@ -598,4 +598,4 @@ declare const types: {
|
|
|
598
598
|
GameHighScore: ApiType;
|
|
599
599
|
};
|
|
600
600
|
//#endregion
|
|
601
|
-
export { ApiMethod, ApiType, ApiTypeObject, ApiTypeOneOf, Description, FieldOrParam, ValueType, ValueTypeApiType, ValueTypeArray, ValueTypeBoolean, ValueTypeFloat, ValueTypeInputFile, ValueTypeInteger32,
|
|
601
|
+
export { ApiMethod, ApiType, ApiTypeObject, ApiTypeOneOf, Description, FieldOrParam, ValueType, ValueTypeApiType, ValueTypeArray, ValueTypeBoolean, ValueTypeFloat, ValueTypeInputFile, ValueTypeInteger32, ValueTypeInteger53, ValueTypeString, ValueTypeUnion, methods, types };
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
//#region src/bot-api/methods.gen.ts
|
|
2
2
|
const getUpdates = {
|
|
3
3
|
name: "getUpdates",
|
|
4
|
-
description: { markdown: "Use this method to receive incoming updates using long polling ([wiki](https://en.wikipedia.org/wiki/Push_technology#Long_polling)). Returns an Array of [Update](https://core.telegram.org/bots/api#update) objects.\n\n> **Notes
|
|
4
|
+
description: { markdown: "Use this method to receive incoming updates using long polling ([wiki](https://en.wikipedia.org/wiki/Push_technology#Long_polling)). Returns an Array of [Update](https://core.telegram.org/bots/api#update) objects.\n\n> **Notes**\n> \n> **1.** This method will not work if an outgoing webhook is set up.\n> \n> **2.** In order to avoid getting duplicate updates, recalculate _offset_ after each server response." },
|
|
5
5
|
parameters: [
|
|
6
6
|
{
|
|
7
7
|
name: "offset",
|
|
@@ -30,7 +30,7 @@ const getUpdates = {
|
|
|
30
30
|
type: "array",
|
|
31
31
|
of: { type: "str" }
|
|
32
32
|
},
|
|
33
|
-
description: { markdown: "An array of the update types you want your bot to receive. For example, specify `[\"message\", \"edited_channel_post\", \"callback_query\"]` to only receive updates of these types. See [Update](https://core.telegram.org/bots/api#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
|
|
33
|
+
description: { markdown: "An array of the update types you want your bot to receive. For example, specify `[\"message\", \"edited_channel_post\", \"callback_query\"]` to only receive updates of these types. See [Update](https://core.telegram.org/bots/api#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't affect updates created before the call to getUpdates, so unwanted updates may be received for a short period of time." },
|
|
34
34
|
required: false,
|
|
35
35
|
jsonSerialized: true
|
|
36
36
|
}
|
|
@@ -45,7 +45,7 @@ const getUpdates = {
|
|
|
45
45
|
};
|
|
46
46
|
const setWebhook = {
|
|
47
47
|
name: "setWebhook",
|
|
48
|
-
description: { markdown: "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](https://core.telegram.org/bots/api#update). In case of an unsuccessful request (a request with response [HTTP status code](https://en.wikipedia.org/wiki/List_of_HTTP_status_codes) different from `2XY`), we will repeat the request and give up after a reasonable amount of attempts. Returns _True_ on success.\n\nIf you'd like to make sure that the webhook was set by you, you can specify secret data in the parameter _secret\\_token_. If specified, the request will contain a header “X-Telegram-Bot-Api-Secret-Token” with the secret token as content.\n\n> **Notes
|
|
48
|
+
description: { markdown: "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](https://core.telegram.org/bots/api#update). In case of an unsuccessful request (a request with response [HTTP status code](https://en.wikipedia.org/wiki/List_of_HTTP_status_codes) different from `2XY`), we will repeat the request and give up after a reasonable amount of attempts. Returns _True_ on success.\n\nIf you'd like to make sure that the webhook was set by you, you can specify secret data in the parameter _secret\\_token_. If specified, the request will contain a header “X-Telegram-Bot-Api-Secret-Token” with the secret token as content.\n\n> **Notes**\n> \n> **1.** You will not be able to receive updates using [getUpdates](https://core.telegram.org/bots/api#getupdates) for as long as an outgoing webhook is set up.\n> \n> **2.** To use a self-signed certificate, you need to upload your [public key certificate](https://core.telegram.org/bots/self-signed) using _certificate_ parameter. Please upload as InputFile, sending a String will not work.\n> \n> **3.** Ports currently supported _for webhooks_: **443, 80, 88, 8443**.\n> \n> If you're having any trouble setting up webhooks, please check out this [amazing guide to webhooks](https://core.telegram.org/bots/webhooks)." },
|
|
49
49
|
parameters: [
|
|
50
50
|
{
|
|
51
51
|
name: "url",
|
|
@@ -81,7 +81,7 @@ const setWebhook = {
|
|
|
81
81
|
type: "array",
|
|
82
82
|
of: { type: "str" }
|
|
83
83
|
},
|
|
84
|
-
description: { markdown: "An array of the update types you want your bot to receive. For example, specify `[\"message\", \"edited_channel_post\", \"callback_query\"]` to only receive updates of these types. See [Update](https://core.telegram.org/bots/api#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
|
|
84
|
+
description: { markdown: "An array of the update types you want your bot to receive. For example, specify `[\"message\", \"edited_channel_post\", \"callback_query\"]` to only receive updates of these types. See [Update](https://core.telegram.org/bots/api#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't affect updates created before the call to the setWebhook, so unwanted updates may be received for a short period of time." },
|
|
85
85
|
required: false,
|
|
86
86
|
jsonSerialized: true
|
|
87
87
|
},
|
|
@@ -4587,7 +4587,7 @@ const answerCallbackQuery = {
|
|
|
4587
4587
|
{
|
|
4588
4588
|
name: "url",
|
|
4589
4589
|
type: { type: "str" },
|
|
4590
|
-
description: { markdown: "URL that will be opened by the user's client. If you have created a [Game](https://core.telegram.org/bots/api#game) and accepted the conditions via [@BotFather](https://t.me/botfather), specify the URL that opens your game - note that this will only work if the query comes from a [_callback\\_game_](https://core.telegram.org/bots/api#inlinekeyboardbutton) button
|
|
4590
|
+
description: { markdown: "URL that will be opened by the user's client. If you have created a [Game](https://core.telegram.org/bots/api#game) and accepted the conditions via [@BotFather](https://t.me/botfather), specify the URL that opens your game - note that this will only work if the query comes from a [_callback\\_game_](https://core.telegram.org/bots/api#inlinekeyboardbutton) button.\n\nOtherwise, you may use links like `t.me/your_bot?start=XXXX` that open your bot with a parameter." },
|
|
4591
4591
|
required: false,
|
|
4592
4592
|
jsonSerialized: false
|
|
4593
4593
|
},
|
|
@@ -6351,7 +6351,7 @@ const declineSuggestedPost = {
|
|
|
6351
6351
|
};
|
|
6352
6352
|
const deleteMessage = {
|
|
6353
6353
|
name: "deleteMessage",
|
|
6354
|
-
description: { markdown: "Use this method to delete a message, including service messages, with the following limitations
|
|
6354
|
+
description: { markdown: "Use this method to delete a message, including service messages, with the following limitations:\n\n\\- A message can only be deleted if it was sent less than 48 hours ago.\n\n\\- Service messages about a supergroup, channel, or forum topic creation can't be deleted.\n\n\\- A dice message in a private chat can only be deleted if it was sent more than 24 hours ago.\n\n\\- Bots can delete outgoing messages in private chats, groups, and supergroups.\n\n\\- Bots can delete incoming messages in private chats.\n\n\\- Bots granted _can\\_post\\_messages_ permissions can delete outgoing messages in channels.\n\n\\- If the bot is an administrator of a group, it can delete any message there.\n\n\\- If the bot has _can\\_delete\\_messages_ administrator right in a supergroup or a channel, it can delete any message there.\n\n\\- If the bot has _can\\_manage\\_direct\\_messages_ administrator right in a channel, it can delete any message in the corresponding direct messages chat.\n\nReturns _True_ on success." },
|
|
6355
6355
|
parameters: [{
|
|
6356
6356
|
name: "chat_id",
|
|
6357
6357
|
type: {
|
|
@@ -6941,7 +6941,7 @@ const deleteStickerSet = {
|
|
|
6941
6941
|
};
|
|
6942
6942
|
const answerInlineQuery = {
|
|
6943
6943
|
name: "answerInlineQuery",
|
|
6944
|
-
description: { markdown: "Use this method to send answers to an inline query. On success, _True_ is returned
|
|
6944
|
+
description: { markdown: "Use this method to send answers to an inline query. On success, _True_ is returned.\n\nNo more than **50** results per query are allowed." },
|
|
6945
6945
|
parameters: [
|
|
6946
6946
|
{
|
|
6947
6947
|
name: "inline_query_id",
|
|
@@ -8043,7 +8043,7 @@ const methods = {
|
|
|
8043
8043
|
const t = (apiType) => apiType;
|
|
8044
8044
|
const Update = t({
|
|
8045
8045
|
name: "Update",
|
|
8046
|
-
description: { markdown: "This [object](https://core.telegram.org/bots/api#available-types) represents an incoming update
|
|
8046
|
+
description: { markdown: "This [object](https://core.telegram.org/bots/api#available-types) represents an incoming update.\n\nAt most **one** of the optional parameters can be present in any given update." },
|
|
8047
8047
|
fields: [
|
|
8048
8048
|
{
|
|
8049
8049
|
name: "update_id",
|
|
@@ -8362,7 +8362,7 @@ const User = t({
|
|
|
8362
8362
|
fields: [
|
|
8363
8363
|
{
|
|
8364
8364
|
name: "id",
|
|
8365
|
-
type: { type: "
|
|
8365
|
+
type: { type: "int53" },
|
|
8366
8366
|
description: { markdown: "Unique identifier for this user or bot." },
|
|
8367
8367
|
required: true,
|
|
8368
8368
|
jsonSerialized: false
|
|
@@ -8465,7 +8465,7 @@ const Chat = t({
|
|
|
8465
8465
|
fields: [
|
|
8466
8466
|
{
|
|
8467
8467
|
name: "id",
|
|
8468
|
-
type: { type: "
|
|
8468
|
+
type: { type: "int53" },
|
|
8469
8469
|
description: { markdown: "Unique identifier for this chat." },
|
|
8470
8470
|
required: true,
|
|
8471
8471
|
jsonSerialized: false
|
|
@@ -8533,7 +8533,7 @@ const ChatFullInfo = t({
|
|
|
8533
8533
|
fields: [
|
|
8534
8534
|
{
|
|
8535
8535
|
name: "id",
|
|
8536
|
-
type: { type: "
|
|
8536
|
+
type: { type: "int53" },
|
|
8537
8537
|
description: { markdown: "Unique identifier for this chat." },
|
|
8538
8538
|
required: true,
|
|
8539
8539
|
jsonSerialized: false
|
|
@@ -8923,7 +8923,7 @@ const ChatFullInfo = t({
|
|
|
8923
8923
|
},
|
|
8924
8924
|
{
|
|
8925
8925
|
name: "linked_chat_id",
|
|
8926
|
-
type: { type: "
|
|
8926
|
+
type: { type: "int53" },
|
|
8927
8927
|
description: { markdown: "Unique identifier for the linked chat, i.e. the discussion group identifier for a channel and vice versa; for supergroups and channel chats." },
|
|
8928
8928
|
required: false,
|
|
8929
8929
|
jsonSerialized: false
|
|
@@ -9529,14 +9529,14 @@ const Message = t({
|
|
|
9529
9529
|
},
|
|
9530
9530
|
{
|
|
9531
9531
|
name: "migrate_to_chat_id",
|
|
9532
|
-
type: { type: "
|
|
9532
|
+
type: { type: "int53" },
|
|
9533
9533
|
description: { markdown: "The group has been migrated to a supergroup with the specified identifier." },
|
|
9534
9534
|
required: false,
|
|
9535
9535
|
jsonSerialized: false
|
|
9536
9536
|
},
|
|
9537
9537
|
{
|
|
9538
9538
|
name: "migrate_from_chat_id",
|
|
9539
|
-
type: { type: "
|
|
9539
|
+
type: { type: "int53" },
|
|
9540
9540
|
description: { markdown: "The supergroup has been migrated from a group with the specified identifier." },
|
|
9541
9541
|
required: false,
|
|
9542
9542
|
jsonSerialized: false
|
|
@@ -10676,7 +10676,7 @@ const Animation = t({
|
|
|
10676
10676
|
},
|
|
10677
10677
|
{
|
|
10678
10678
|
name: "file_size",
|
|
10679
|
-
type: { type: "
|
|
10679
|
+
type: { type: "int53" },
|
|
10680
10680
|
description: { markdown: "File size in bytes." },
|
|
10681
10681
|
required: false,
|
|
10682
10682
|
jsonSerialized: false
|
|
@@ -10738,7 +10738,7 @@ const Audio = t({
|
|
|
10738
10738
|
},
|
|
10739
10739
|
{
|
|
10740
10740
|
name: "file_size",
|
|
10741
|
-
type: { type: "
|
|
10741
|
+
type: { type: "int53" },
|
|
10742
10742
|
description: { markdown: "File size in bytes." },
|
|
10743
10743
|
required: false,
|
|
10744
10744
|
jsonSerialized: false
|
|
@@ -10799,7 +10799,7 @@ const Document = t({
|
|
|
10799
10799
|
},
|
|
10800
10800
|
{
|
|
10801
10801
|
name: "file_size",
|
|
10802
|
-
type: { type: "
|
|
10802
|
+
type: { type: "int53" },
|
|
10803
10803
|
description: { markdown: "File size in bytes." },
|
|
10804
10804
|
required: false,
|
|
10805
10805
|
jsonSerialized: false
|
|
@@ -10911,7 +10911,7 @@ const Video = t({
|
|
|
10911
10911
|
},
|
|
10912
10912
|
{
|
|
10913
10913
|
name: "file_size",
|
|
10914
|
-
type: { type: "
|
|
10914
|
+
type: { type: "int53" },
|
|
10915
10915
|
description: { markdown: "File size in bytes." },
|
|
10916
10916
|
required: false,
|
|
10917
10917
|
jsonSerialized: false
|
|
@@ -11003,7 +11003,7 @@ const Voice = t({
|
|
|
11003
11003
|
},
|
|
11004
11004
|
{
|
|
11005
11005
|
name: "file_size",
|
|
11006
|
-
type: { type: "
|
|
11006
|
+
type: { type: "int53" },
|
|
11007
11007
|
description: { markdown: "File size in bytes." },
|
|
11008
11008
|
required: false,
|
|
11009
11009
|
jsonSerialized: false
|
|
@@ -11155,7 +11155,7 @@ const Contact = t({
|
|
|
11155
11155
|
},
|
|
11156
11156
|
{
|
|
11157
11157
|
name: "user_id",
|
|
11158
|
-
type: { type: "
|
|
11158
|
+
type: { type: "int53" },
|
|
11159
11159
|
description: { markdown: "Contact's user identifier in Telegram." },
|
|
11160
11160
|
required: false,
|
|
11161
11161
|
jsonSerialized: false
|
|
@@ -12218,7 +12218,7 @@ const SharedUser = t({
|
|
|
12218
12218
|
fields: [
|
|
12219
12219
|
{
|
|
12220
12220
|
name: "user_id",
|
|
12221
|
-
type: { type: "
|
|
12221
|
+
type: { type: "int53" },
|
|
12222
12222
|
description: { markdown: "Identifier of the shared user. The bot may not have access to the user and could be unable to use this identifier, unless the user is already known to the bot by some other means." },
|
|
12223
12223
|
required: true,
|
|
12224
12224
|
jsonSerialized: false
|
|
@@ -12295,7 +12295,7 @@ const ChatShared = t({
|
|
|
12295
12295
|
},
|
|
12296
12296
|
{
|
|
12297
12297
|
name: "chat_id",
|
|
12298
|
-
type: { type: "
|
|
12298
|
+
type: { type: "int53" },
|
|
12299
12299
|
description: { markdown: "Identifier of the shared chat. The bot may not have access to the chat and could be unable to use this identifier, unless the chat is already known to the bot by some other means." },
|
|
12300
12300
|
required: true,
|
|
12301
12301
|
jsonSerialized: false
|
|
@@ -12917,7 +12917,7 @@ const DirectMessagesTopic = t({
|
|
|
12917
12917
|
description: { markdown: "Describes a topic of a direct messages chat." },
|
|
12918
12918
|
fields: [{
|
|
12919
12919
|
name: "topic_id",
|
|
12920
|
-
type: { type: "
|
|
12920
|
+
type: { type: "int53" },
|
|
12921
12921
|
description: { markdown: "Unique identifier of the topic." },
|
|
12922
12922
|
required: true,
|
|
12923
12923
|
jsonSerialized: false
|
|
@@ -12978,7 +12978,7 @@ const File = t({
|
|
|
12978
12978
|
},
|
|
12979
12979
|
{
|
|
12980
12980
|
name: "file_size",
|
|
12981
|
-
type: { type: "
|
|
12981
|
+
type: { type: "int53" },
|
|
12982
12982
|
description: { markdown: "File size in bytes." },
|
|
12983
12983
|
required: false,
|
|
12984
12984
|
jsonSerialized: false
|
|
@@ -13054,7 +13054,7 @@ const ReplyKeyboardMarkup = t({
|
|
|
13054
13054
|
{
|
|
13055
13055
|
name: "selective",
|
|
13056
13056
|
type: { type: "bool" },
|
|
13057
|
-
description: { markdown: "Use this parameter if you want to show the keyboard to specific users only. Targets: 1) users that are @mentioned in the _text_ of the [Message](https://core.telegram.org/bots/api#message) object; 2) if the bot's message is a reply to a message in the same chat and forum topic, sender of the original message
|
|
13057
|
+
description: { markdown: "Use this parameter if you want to show the keyboard to specific users only. Targets: 1) users that are @mentioned in the _text_ of the [Message](https://core.telegram.org/bots/api#message) object; 2) if the bot's message is a reply to a message in the same chat and forum topic, sender of the original message.\n\n_Example:_ A user requests to change the bot's language, bot replies to the request with a keyboard to select the new language. Other users in the group don't see the keyboard." },
|
|
13058
13058
|
required: false,
|
|
13059
13059
|
jsonSerialized: false
|
|
13060
13060
|
}
|
|
@@ -13297,7 +13297,7 @@ const ReplyKeyboardRemove = t({
|
|
|
13297
13297
|
}, {
|
|
13298
13298
|
name: "selective",
|
|
13299
13299
|
type: { type: "bool" },
|
|
13300
|
-
description: { markdown: "Use this parameter if you want to remove the keyboard for specific users only. Targets: 1) users that are @mentioned in the _text_ of the [Message](https://core.telegram.org/bots/api#message) object; 2) if the bot's message is a reply to a message in the same chat and forum topic, sender of the original message
|
|
13300
|
+
description: { markdown: "Use this parameter if you want to remove the keyboard for specific users only. Targets: 1) users that are @mentioned in the _text_ of the [Message](https://core.telegram.org/bots/api#message) object; 2) if the bot's message is a reply to a message in the same chat and forum topic, sender of the original message.\n\n_Example:_ A user votes in a poll, bot returns confirmation message in reply to the vote and removes the keyboard for that user, while still showing the keyboard with poll options to users who haven't voted yet." },
|
|
13301
13301
|
required: false,
|
|
13302
13302
|
jsonSerialized: false
|
|
13303
13303
|
}]
|
|
@@ -13377,7 +13377,7 @@ const InlineKeyboardButton = t({
|
|
|
13377
13377
|
{
|
|
13378
13378
|
name: "switch_inline_query_current_chat",
|
|
13379
13379
|
type: { type: "str" },
|
|
13380
|
-
description: { markdown: "If set, pressing the button will insert the bot's username and the specified inline query in the current chat's input field. May be empty, in which case only the bot's username will be inserted
|
|
13380
|
+
description: { markdown: "If set, pressing the button will insert the bot's username and the specified inline query in the current chat's input field. May be empty, in which case only the bot's username will be inserted.\n\nThis offers a quick way for the user to open your bot in inline mode in the same chat - good for selecting something from multiple options. Not supported in channels and for messages sent in channel direct messages chats and on behalf of a Telegram Business account." },
|
|
13381
13381
|
required: false,
|
|
13382
13382
|
jsonSerialized: false
|
|
13383
13383
|
},
|
|
@@ -13407,14 +13407,14 @@ const InlineKeyboardButton = t({
|
|
|
13407
13407
|
type: "api-type",
|
|
13408
13408
|
name: "CallbackGame"
|
|
13409
13409
|
},
|
|
13410
|
-
description: { markdown: "Description of the game that will be launched when the user presses the button
|
|
13410
|
+
description: { markdown: "Description of the game that will be launched when the user presses the button.\n\n**NOTE:** This type of button **must** always be the first button in the first row." },
|
|
13411
13411
|
required: false,
|
|
13412
13412
|
jsonSerialized: false
|
|
13413
13413
|
},
|
|
13414
13414
|
{
|
|
13415
13415
|
name: "pay",
|
|
13416
13416
|
type: { type: "bool" },
|
|
13417
|
-
description: { markdown: "Specify _True_, to send a [Pay button](https://core.telegram.org/bots/api#payments). Substrings “” and “XTR” in the buttons's text will be replaced with a Telegram Star icon
|
|
13417
|
+
description: { markdown: "Specify _True_, to send a [Pay button](https://core.telegram.org/bots/api#payments). Substrings “” and “XTR” in the buttons's text will be replaced with a Telegram Star icon.\n\n**NOTE:** This type of button **must** always be the first button in the first row and can only be used in invoice messages." },
|
|
13418
13418
|
required: false,
|
|
13419
13419
|
jsonSerialized: false
|
|
13420
13420
|
}
|
|
@@ -13427,7 +13427,7 @@ const LoginUrl = t({
|
|
|
13427
13427
|
{
|
|
13428
13428
|
name: "url",
|
|
13429
13429
|
type: { type: "str" },
|
|
13430
|
-
description: { markdown: "An HTTPS URL to be opened with user authorization data added to the query string when the button is pressed. If the user refuses to provide authorization data, the original URL without information about the user will be opened. The data added is the same as described in [Receiving authorization data](https://core.telegram.org/widgets/login#receiving-authorization-data)
|
|
13430
|
+
description: { markdown: "An HTTPS URL to be opened with user authorization data added to the query string when the button is pressed. If the user refuses to provide authorization data, the original URL without information about the user will be opened. The data added is the same as described in [Receiving authorization data](https://core.telegram.org/widgets/login#receiving-authorization-data).\n\n**NOTE:** You **must** always check the hash of the received data to verify the authentication and the integrity of the data as described in [Checking authorization](https://core.telegram.org/widgets/login#checking-authorization)." },
|
|
13431
13431
|
required: true,
|
|
13432
13432
|
jsonSerialized: false
|
|
13433
13433
|
},
|
|
@@ -14369,7 +14369,7 @@ const ChatJoinRequest = t({
|
|
|
14369
14369
|
},
|
|
14370
14370
|
{
|
|
14371
14371
|
name: "user_chat_id",
|
|
14372
|
-
type: { type: "
|
|
14372
|
+
type: { type: "int53" },
|
|
14373
14373
|
description: { markdown: "Identifier of a private chat with the user who sent the join request. The bot can use this identifier for 5 minutes to send messages until the join request is processed, assuming no other administrator contacted the user." },
|
|
14374
14374
|
required: true,
|
|
14375
14375
|
jsonSerialized: false
|
|
@@ -16503,7 +16503,7 @@ const BusinessConnection = t({
|
|
|
16503
16503
|
},
|
|
16504
16504
|
{
|
|
16505
16505
|
name: "user_chat_id",
|
|
16506
|
-
type: { type: "
|
|
16506
|
+
type: { type: "int53" },
|
|
16507
16507
|
description: { markdown: "Identifier of a private chat with the user who created the business connection." },
|
|
16508
16508
|
required: true,
|
|
16509
16509
|
jsonSerialized: false
|
|
@@ -16572,7 +16572,7 @@ const ResponseParameters = t({
|
|
|
16572
16572
|
description: { markdown: "Describes why a request was unsuccessful." },
|
|
16573
16573
|
fields: [{
|
|
16574
16574
|
name: "migrate_to_chat_id",
|
|
16575
|
-
type: { type: "
|
|
16575
|
+
type: { type: "int53" },
|
|
16576
16576
|
description: { markdown: "The group has been migrated to a supergroup with the specified identifier." },
|
|
16577
16577
|
required: false,
|
|
16578
16578
|
jsonSerialized: false
|
|
@@ -17562,7 +17562,7 @@ const InlineQueryResultsButton = t({
|
|
|
17562
17562
|
{
|
|
17563
17563
|
name: "start_parameter",
|
|
17564
17564
|
type: { type: "str" },
|
|
17565
|
-
description: { markdown: "[Deep-linking](https://core.telegram.org/bots/features#deep-linking) parameter for the /start message sent to the bot when a user presses the button. 1-64 characters, only `A-Z`, `a-z`, `0-9`, `_` and `-` are allowed
|
|
17565
|
+
description: { markdown: "[Deep-linking](https://core.telegram.org/bots/features#deep-linking) parameter for the /start message sent to the bot when a user presses the button. 1-64 characters, only `A-Z`, `a-z`, `0-9`, `_` and `-` are allowed.\n\n_Example:_ An inline bot that sends YouTube videos can ask the user to connect the bot to their YouTube account to adapt search results accordingly. To do this, it displays a 'Connect your YouTube account' button above the results, or even before showing any. The user presses the button, switches to a private chat with the bot and, in doing so, passes a start parameter that instructs the bot to return an OAuth link. Once done, the bot can offer a [_switch\\_inline_](https://core.telegram.org/bots/api#inlinekeyboardmarkup) button so that the user can easily return to the chat where they wanted to use the bot's inline capabilities." },
|
|
17566
17566
|
required: false,
|
|
17567
17567
|
jsonSerialized: false
|
|
17568
17568
|
}
|
package/package.json
CHANGED