File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -24,6 +24,8 @@ export declare class TelegrafContext {
2424 message ?: tt . IncomingMessage
2525 preCheckoutQuery ?: tt . PreCheckoutQuery
2626 shippingQuery ?: tt . ShippingQuery
27+ poll : tt . Poll
28+ pollAnswer : tt . PollAnswer
2729
2830 constructor (
2931 update : tt . Update ,
Original file line number Diff line number Diff line change @@ -30,7 +30,9 @@ export type UpdateType =
3030 'inline_query' |
3131 'message' |
3232 'pre_checkout_query' |
33- 'shipping_query'
33+ 'shipping_query' |
34+ 'poll' |
35+ 'poll_answer'
3436
3537export type MessageSubTypes =
3638 'voice' |
@@ -760,13 +762,27 @@ export interface PollOption {
760762 voter_count : number
761763}
762764
765+ export interface PollAnswer {
766+ /** Unique poll identifier */
767+ poll_id : string
768+
769+ /** The user, who changed the answer to the poll */
770+ user : TT . User
771+
772+ /** 0-based identifiers of answer options, chosen by the user. May be empty if the user retracted their vote. */
773+ option_ids : number [ ]
774+ }
775+
763776export interface Poll {
764777 /** Unique poll identifier */
765778 id : string
766779
767780 /** Poll question, 1-255 characters */
768781 question : string
769782
783+ /** List of poll options */
784+ options : PollOption [ ]
785+
770786 /** Total number of users that voted in the poll */
771787 total_voter_count : number
772788
You can’t perform that action at this time.
0 commit comments