You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/tourmaline/client/api.cr
+106-2Lines changed: 106 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,7 @@ module Tourmaline
20
20
})
21
21
end
22
22
23
-
# 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.
23
+
# 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.
24
24
# If 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.
# Use this method to send an animated emoji that will display a random value. On success, the sent Message is returned.
769
795
defsend_dice(
770
796
chat_id : Int32|Int64|String,
@@ -812,7 +838,7 @@ module Tourmaline
812
838
})
813
839
end
814
840
815
-
# Use this method to change the chosen reactions on a message. Service messages can't be reacted to. Automatically forwarded messages from a channel to its discussion group have the same available reactions as messages in the channel. Returns True on success.
841
+
# Use this method to change the chosen reactions on a message. Service messages of some types can't be reacted to. Automatically forwarded messages from a channel to its discussion group have the same available reactions as messages in the channel. Bots can't use paid reactions. Returns True on success.
816
842
defset_message_reaction(
817
843
chat_id : Int32|Int64|String,
818
844
message_id : Int32|Int64,
@@ -840,6 +866,19 @@ module Tourmaline
840
866
})
841
867
end
842
868
869
+
# 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.
# Use this method to get basic information about a file and prepare it for downloading. For the moment, bots can download files of up to 20MB in size. On success, a File object is returned. The file can then be downloaded via the link https://api.telegram.org/file/bot<token>/<file_path>, where <file_path> is taken from the response. It is guaranteed that the link will be valid for at least 1 hour. When the link expires, a new one can be requested by calling getFile again.
844
883
# Note: This function may not preserve the original file name and MIME type. You should save the file's MIME type and name (if available) when the File object is received.
845
884
defget_file(
@@ -2332,6 +2371,25 @@ module Tourmaline
2332
2371
})
2333
2372
end
2334
2373
2374
+
# Stores a message that can be sent by a user of a Mini App. Returns a PreparedInlineMessage object.
# Informs a user that some of the Telegram Passport elements they provided contains errors. The user will not be able to re-submit their Passport to you until the errors are fixed (the contents of the field for which you returned the error must change). Returns True on success.
2478
2582
# Use this if the data submitted by the user doesn't satisfy the standards your service requires for any reason. For example, if a birthday date seems invalid, a submitted document is blurry, a scan shows evidence of tampering, etc. Supply some details in the error message to make sure the user knows how to correct the issues.
0 commit comments