peyk.platforms.bale.types.sticker

Classes

Sticker(file_id, file_unique_id, type, ...)

Represent the Bale Bot API Sticker object.

class peyk.platforms.bale.types.sticker.Sticker(file_id: str, file_unique_id: str, type: str, width: int, height: int, file_size: int | None = None)[source]

Bases: object

Represent the Bale Bot API Sticker object.

Preserves the existing dataclass fields and parsing behavior.

file_id: str
file_unique_id: str
type: str
width: int
height: int
file_size: int | None = None
classmethod from_dict(data: dict | None) Sticker | None[source]

Parse raw Bale data into Sticker.

Parameters:

data (Optional[dict]) – Raw API object or None.

Returns:

Parsed object or None.

Return type:

Optional[Sticker]

Raises:

KeyError – If a required raw field is missing.