Poll#

class pyrogram.raw.types.Poll#

Poll.

Constructor of Poll.

Details:
  • Layer: 158

  • ID: 86E18161

Parameters:
  • id (int 64-bit) – ID of the poll.

  • question (str) – The question of the poll.

  • answers (List of PollAnswer) – The possible answers, vote using messages.sendVote.

  • closed (bool, optional) – Whether the poll is closed and doesn’t accept any more answers.

  • public_voters (bool, optional) – Whether cast votes are publicly visible to all users (non-anonymous poll).

  • multiple_choice (bool, optional) – Whether multiple options can be chosen as answer.

  • quiz (bool, optional) – Whether this is a quiz (with wrong and correct answers, results shown in the return type).

  • close_period (int 32-bit, optional) – Amount of time in seconds the poll will be active after creation, 5-600. Can’t be used together with close_date.

  • close_date (int 32-bit, optional) – Point in time (Unix timestamp) when the poll will be automatically closed. Must be at least 5 and no more than 600 seconds in the future; can’t be used together with close_period.