Skip to content

class Tourmaline::Sticker
inherits Reference #

This object represents a sticker.

Included modules

JSON::Serializable

Constructors#

.new(file_id, file_unique_id, type, width, height, is_animated, is_video, thumbnail : Tourmaline::PhotoSize? = nil, emoji : String? = nil, set_name : String? = nil, premium_animation : Tourmaline::File? = nil, mask_position : Tourmaline::MaskPosition? = nil, custom_emoji_id : String? = nil, needs_repainting : Bool? = nil, file_size : Int32 | Int64 | Nil = nil) #

View source

.new(pull : JSON::PullParser) #

View source

Methods#

#custom_emoji_id : String? #

Optional. For custom emoji stickers, unique identifier of the custom emoji

View source

#custom_emoji_id=(custom_emoji_id : String?) #

Optional. For custom emoji stickers, unique identifier of the custom emoji

View source

#emoji : String? #

Optional. Emoji associated with the sticker

View source

#emoji=(emoji : String?) #

Optional. Emoji associated with the sticker

View source

#file_id : String #

Identifier for this file, which can be used to download or reuse the file

View source

#file_id=(file_id : String) #

Identifier for this file, which can be used to download or reuse the file

View source

#file_size : Int32 | Int64 | Nil #

Optional. File size in bytes

View source

#file_size=(file_size : Int32 | Int64 | Nil) #

Optional. File size in bytes

View source

#file_unique_id : String #

Unique identifier for this file, which is supposed to be the same over time and for different bots. Can't be used to download or reuse the file.

View source

#file_unique_id=(file_unique_id : String) #

Unique identifier for this file, which is supposed to be the same over time and for different bots. Can't be used to download or reuse the file.

View source

#height : Int32 | Int64 #

Sticker height

View source

#height=(height : Int32 | Int64) #

Sticker height

View source

#is_animated=(is_animated : Bool) #

True, if the sticker is animated

View source

#is_animated? : Bool #

True, if the sticker is animated

View source

#is_video=(is_video : Bool) #

True, if the sticker is a video sticker

View source

#is_video? : Bool #

True, if the sticker is a video sticker

View source

#mask_position : Tourmaline::MaskPosition? #

Optional. For mask stickers, the position where the mask should be placed

View source

#mask_position=(mask_position : Tourmaline::MaskPosition?) #

Optional. For mask stickers, the position where the mask should be placed

View source

#needs_repainting=(needs_repainting : Bool?) #

Optional. True, if the sticker must be repainted to a text color in messages, the color of the Telegram Premium badge in emoji status, white color on chat photos, or another appropriate color in other places

View source

#needs_repainting? : Bool? #

Optional. True, if the sticker must be repainted to a text color in messages, the color of the Telegram Premium badge in emoji status, white color on chat photos, or another appropriate color in other places

View source

#premium_animation : Tourmaline::File? #

Optional. For premium regular stickers, premium animation for the sticker

View source

#premium_animation=(premium_animation : Tourmaline::File?) #

Optional. For premium regular stickers, premium animation for the sticker

View source

#set_name : String? #

Optional. Name of the sticker set to which the sticker belongs

View source

#set_name=(set_name : String?) #

Optional. Name of the sticker set to which the sticker belongs

View source

#thumbnail : Tourmaline::PhotoSize? #

Optional. Sticker thumbnail in the .WEBP or .JPG format

View source

#thumbnail=(thumbnail : Tourmaline::PhotoSize?) #

Optional. Sticker thumbnail in the .WEBP or .JPG format

View source

#type : String #

Type of the sticker, currently one of "regular", "mask", "custom_emoji". The type of the sticker is independent from its format, which is determined by the fields is_animated and is_video.

View source

#type=(type : String) #

Type of the sticker, currently one of "regular", "mask", "custom_emoji". The type of the sticker is independent from its format, which is determined by the fields is_animated and is_video.

View source

#width : Int32 | Int64 #

Sticker width

View source

#width=(width : Int32 | Int64) #

Sticker width

View source