peyk.platforms.bale.types.chat_photo

Classes

ChatPhoto(small_file_id, ...)

Represent the Bale Bot API ChatPhoto object.

class peyk.platforms.bale.types.chat_photo.ChatPhoto(small_file_id: str, small_file_unique_id: str, big_file_id: str, big_file_unique_id: str)[source]

Bases: object

Represent the Bale Bot API ChatPhoto object.

Preserves the existing dataclass fields and parsing behavior.

small_file_id: str
small_file_unique_id: str
big_file_id: str
big_file_unique_id: str
classmethod from_dict(data: dict | None) ChatPhoto | None[source]

Parse raw Bale data into ChatPhoto.

Parameters:

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

Returns:

Parsed object or None.

Return type:

Optional[ChatPhoto]

Raises:

KeyError – If a required raw field is missing.