DocumentAttributeAudio

class pyrogram.raw.types.DocumentAttributeAudio

Represents an audio file

Constructor of DocumentAttribute.

Details:
  • Layer: 223

  • ID: 9852F9C6

Parameters:
  • duration (int 32-bit) – Duration in seconds

  • voice (bool, optional) – Whether this is a voice message

  • title (str, optional) – Name of song

  • performer (str, optional) – Performer

  • waveform (bytes, optional) – Waveform: consists in a series of bitpacked 5-bit values. Example implementation: android.

TL Schema

documentAttributeAudio#9852f9c6
flags:#
voice:flags.10?true
duration:int
title:flags.0?string
performer:flags.1?string
waveform:flags.2?bytes

= DocumentAttribute

Parameter Tree

DocumentAttributeAudio
├── voicetrue (optional)
├── durationint
├── titlestring (optional)
├── performerstring (optional)
└── waveformbytes (optional)

Example

DocumentAttributeAudio(
    duration=0,
)