1.2 KiB
1.2 KiB
title | description |
---|---|
voice | Describes voice record. Voice must be encoded with Opus codec and must be stored inside Ogg container |
Constructor: voice
Describes voice record. Voice must be encoded with Opus codec and must be stored inside Ogg container
Attributes:
Name | Type | Required | Description |
---|---|---|---|
duration | int | Yes | Duration of the voice record in seconds as defined by sender |
waveform | bytes | Yes | Waveform representation of the voice in 5-bit format |
mime_type | string | Yes | MIME type of a file as defined by sender |
voice | file | Yes | File with the voice record |
Type: Voice
Example:
$voice = ['_' => 'voice', 'duration' => int, 'waveform' => 'bytes', 'mime_type' => 'string', 'voice' => file];
PWRTelegram json-encoded version:
{"_": "voice", "duration": int, "waveform": "bytes", "mime_type": "string", "voice": file}
Or, if you're into Lua:
voice={_='voice', duration=int, waveform='bytes', mime_type='string', voice=file}