class Hamilton::Types::Sticker

Overview

This object represents a sticker.

Included Modules

Defined in:

types/sticker.cr

Constructors

Instance Method Summary

Instance methods inherited from class Reference

==(other : Hamilton::Any) ==

Instance methods inherited from class Object

===(other : Hamilton::Any) ===

Constructor Detail

def self.new(pull : JSON::PullParser) #

def self.new(params) #

def self.new(*, __pull_for_json_serializable pull : JSON::PullParser) #

def self.new(**params) #

Instance Method Detail

def custom_emoji_id : String | Nil #

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


def custom_emoji_id=(custom_emoji_id : String | Nil) #

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


def emoji : String | Nil #

Emoji associated with the sticker.


def emoji=(emoji : String | Nil) #

Emoji associated with the sticker.


def file_id : String #

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


def file_id=(file_id : String) #

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


def file_size : Int32 | Nil #

File size in bytes.


def file_size=(file_size : Int32 | Nil) #

File size in bytes.


def 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.


def 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.


def height : Int32 #

Sticker height.


def height=(height : Int32) #

Sticker height.


def is_animated : Bool #

True, if the sticker is animated.


def is_animated=(is_animated : Bool) #

True, if the sticker is animated.


def is_video : Bool #

True, if the sticker is a video sticker.


def is_video=(is_video : Bool) #

True, if the sticker is a video sticker.


def mask_position : Hamilton::Types::MaskPosition | Nil #

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


def mask_position=(mask_position : Hamilton::Types::MaskPosition | Nil) #

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


def needs_repainting : Bool | Nil #

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.


def needs_repainting=(needs_repainting : Bool | Nil) #

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.


def non_nil_fields : Array(String) #

List of available non-nil fields.


def non_nil_fields=(non_nil_fields : Array(String)) #

List of available non-nil fields.


def premium_animation : Hamilton::Types::File | Nil #

For premium regular stickers, premium animation for the sticker.


def premium_animation=(premium_animation : Hamilton::Types::File | Nil) #

For premium regular stickers, premium animation for the sticker.


def set_name : String | Nil #

Name of the sticker set to which the sticker belongs.


def set_name=(set_name : String | Nil) #

Name of the sticker set to which the sticker belongs.


def thumbnail : Hamilton::Types::PhotoSize | Nil #

Sticker thumbnail in the .WEBP or .JPG format.


def thumbnail=(thumbnail : Hamilton::Types::PhotoSize | Nil) #

Sticker thumbnail in the .WEBP or .JPG format.


def 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.


def 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.


def width : Int32 #

Sticker width.


def width=(width : Int32) #

Sticker width.