/** * MTKruto - Cross-runtime JavaScript library for building Telegram clients * Copyright (C) 2023-2026 Roj * * This file is part of MTKruto. * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public License * along with this program. If not, see . */ import { Api } from "../2_tl.js"; import { type MessageEntity } from "./2_message_entity.js"; import { type PollOption } from "./3_poll_option.js"; /** A poll. */ export interface Poll { /** The identifier of the poll. */ id: string; /** The poll's question. */ question: string; /** The entities of the poll's question. */ questionEntities: MessageEntity[]; /** The poll's options. */ options: PollOption[]; /** The number of users who have participated in the poll. */ totalVoterCount: number; /** Whether the poll is closed. */ isClosed: boolean; /** Whether the poll is anonymous. */ isAnonymous: boolean; /** The type of the poll. */ type: "regular" | "quiz"; /** Whether the poll allows multiple answers. */ allowMultipleAnswers?: boolean; /** The indexes of correct options. */ correctOptionIndexes?: number[]; /** A text that is shown to the user when the poll is answered. */ explanation?: string; /** The explanation's entities. */ explanationEntities?: MessageEntity[]; /** Duration of the poll in seconds. */ openPeriod?: number; /** The time when the poll will be closed. */ closeDate?: number; /** The codes of the countries where the poll is available. */ countries?: string[]; } export declare function constructPoll(media_: Api.messageMediaPoll): Poll; //# sourceMappingURL=4_poll.d.ts.map