DocumentAttribute

class pyrogram.raw.base.DocumentAttribute

Various possible attributes of a document (used to define if it’s a sticker, a GIF, a video, a mask sticker, an image, an audio, and so on)

Constructors:

This base type has 8 constructors available.

DocumentAttributeAnimated

Defines an animated GIF

DocumentAttributeAudio

Represents an audio file

DocumentAttributeCustomEmoji

Info about a custom emoji

DocumentAttributeFilename

A simple document with a file name

DocumentAttributeHasStickers

Whether the current document has stickers attached

DocumentAttributeImageSize

Defines the width and height of an image uploaded as document

DocumentAttributeSticker

Defines a sticker

DocumentAttributeVideo

Defines a video

TL Schema


Parameter Tree

DocumentAttribute
│ ├── wint
│ └── hint
│ ├── masktrue (optional)
│ ├── altstring
│ ├── stickersetInputStickerSet
│ │ ├── InputStickerSetEmpty
│ │ ├── InputStickerSetID
│ │ │ ├── idlong
│ │ │ └── access_hashlong
│ │ ├── InputStickerSetShortName
│ │ │ └── short_namestring
│ │ ├── InputStickerSetDice
│ │ │ └── emoticonstring
│ │ ├── InputStickerSetPremiumGifts
│ │ └── InputStickerSetTonGifts
│ └── mask_coordsMaskCoords (optional)
│ └── MaskCoords
│ ├── nint
│ ├── xdouble
│ ├── ydouble
│ └── zoomdouble
│ ├── round_messagetrue (optional)
│ ├── supports_streamingtrue (optional)
│ ├── nosoundtrue (optional)
│ ├── durationdouble
│ ├── wint
│ ├── hint
│ ├── preload_prefix_sizeint (optional)
│ ├── video_start_tsdouble (optional)
│ └── video_codecstring (optional)
│ ├── voicetrue (optional)
│ ├── durationint
│ ├── titlestring (optional)
│ ├── performerstring (optional)
│ └── waveformbytes (optional)
│ └── file_namestring
├── freetrue (optional)
├── text_colortrue (optional)
├── altstring
└── stickersetInputStickerSet
│ ├── idlong
│ └── access_hashlong
│ └── short_namestring
│ └── emoticonstring

Example