PhotoSize
This object represents one size of a photo or a file / sticker thumbnail.
📝 Schema
Field | Type | Description |
---|---|---|
file_id | String | Identifier for this file, which can be used to download or reuse the file |
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. |
width | Integer | Photo width |
height | Integer | Photo height |
file_size | Integer | Optional. File size in bytes |
⚙️ Get methods
getFileId()
Retrieves the identifier for this file, which can be used to download or reuse the file.
$photoSizeFileId = $photoSizeObject->getFileId();
getFileUniqueId()
Retrieves the unique identifier for this file, which remains constant over time and across different bots.
$photoSizeFileUniqueId = $photoSizeObject->getFileUniqueId();
getWidth()
Retrieves the width of the photo.
$photoSizeWidth = $photoSizeObject->getWidth();
getHeight()
Retrieves the height of the photo.
$photoSizeHeight = $photoSizeObject->getHeight();
getFileSize()
Retrieves the file size in bytes, if available.
$photoSizeFileSize = $photoSizeObject->getFileSize();
➕ More
tip
For further information, refer to the official Bale documentation for more details.