Layer 220
InputMediaPoll
A poll
constructor
inputMediaPoll#f94e5f1 flags:# poll:Poll correct_answers:flags.0?Vector<bytes> solution:flags.1?string solution_entities:flags.1?Vector<MessageEntity> = InputMedia;
Parameters
| Name | Type | Description |
|---|---|---|
| Flags | # | Flags, see TL conditional fields |
| Poll | Poll | The poll to send |
| CorrectAnswers | Vector<bytes> | Correct answer IDs (for quiz polls) |
| Solution | flags.1?string | Explanation of quiz solution |
| SolutionEntities | Vector<MessageEntity> | Message entities for styled text |
Returns
InputMediaGogram Example
// Creating InputMediaPoll constructor obj := &tg.InputMediaPoll{ Poll: &tg.Poll{}, // Optional fields: // CorrectAnswers: []bytes{}, // Solution: "...", // SolutionEntities: []tg.MessageEntity{&tg.MessageEntityBold{Offset: 0, Length: 4}}, }