---
title: "POST /stopPoll"
method: POST
path: "/stopPoll"
---

# POST /stopPoll

`POST /stopPoll`

Use this method to stop a poll which was sent by the bot. On success, the stopped [Poll](https://core.telegram.org/bots/api/#poll) with the final results is returned.

## Request body

- object
  - `chat_id` union, required — Unique identifier for the target chat or username of the target channel (in the format `@channelusername`)
    - integer
    - string
  - `message_id` integer, required — Identifier of the original message with the poll
  - `reply_markup` InlineKeyboardMarkup — This object represents an [inline keyboard](https://core.telegram.org/bots#inline-keyboards-and-on-the-fly-updating) that appears right next to the message it belongs to.
    - `inline_keyboard` array[], required — Array of button rows, each represented by an Array of [InlineKeyboardButton](https://core.telegram.org/bots/api/#inlinekeyboardbutton) objects
      - InlineKeyboardButton[]
        - `text` string, required — Label text on the button
        - `url` string — *Optional*. HTTP or tg:// url to be opened when button is pressed
        - `login_url` LoginUrl — This object represents a parameter of the inline keyboard button used to automatically authorize a user. Serves as a great replacement for the [Telegram Login Widget](https://core.telegram.org/widgets/login) when the user is coming from Telegram. All the user needs to do is tap/click a button and confirm that they want to log in: Telegram apps support these buttons as of [version 5.7](https://telegram.org/blog/privacy-discussions-web-bots#meet-seamless-web-bots). Sample bot: [@discussbot](https://t.me/discussbot)
          - `url` string, required — An HTTP URL to be opened with user authorization data added to the query string when the button is pressed. If the user refuses to provide authorization data, the original URL without information about the user will be opened. The data added is the same as described in [Receiving authorization data](https://core.telegram.org/widgets/login#receiving-authorization-data). **NOTE:** You **must** always check the hash of the received data to verify the authentication and the integrity of the data as described in [Checking authorization](https://core.telegram.org/widgets/login#checking-authorization).
          - `forward_text` string — *Optional*. New text of the button in forwarded messages.
          - `bot_username` string — *Optional*. Username of a bot, which will be used for user authorization. See [Setting up a bot](https://core.telegram.org/widgets/login#setting-up-a-bot) for more details. If not specified, the current bot's username will be assumed. The *url*'s domain must be the same as the domain linked with the bot. See [Linking your domain to the bot](https://core.telegram.org/widgets/login#linking-your-domain-to-the-bot) for more details.
          - `request_write_access` boolean — *Optional*. Pass True to request the permission for your bot to send messages to the user.
        - `callback_data` string — *Optional*. Data to be sent in a [callback query](https://core.telegram.org/bots/api/#callbackquery) to the bot when button is pressed, 1-64 bytes
        - `switch_inline_query` string — *Optional*. If set, pressing the button will prompt the user to select one of their chats, open that chat and insert the bot's username and the specified inline query in the input field. Can be empty, in which case just the bot's username will be inserted. **Note:** This offers an easy way for users to start using your bot in [inline mode](/bots/inline) when they are currently in a private chat with it. Especially useful when combined with [*switch\_pm…*](https://core.telegram.org/bots/api/#answerinlinequery) actions – in this case the user will be automatically returned to the chat they switched from, skipping the chat selection screen.
        - `switch_inline_query_current_chat` string — *Optional*. If set, pressing the button will insert the bot's username and the specified inline query in the current chat's input field. Can be empty, in which case only the bot's username will be inserted. This offers a quick way for the user to open your bot in inline mode in the same chat – good for selecting something from multiple options.
        - `callback_game` unknown
        - `pay` boolean — *Optional*. Specify True, to send a [Pay button](https://core.telegram.org/bots/api/#payments). **NOTE:** This type of button **must** always be the first button in the first row.

## Response `200`

- object
  - `ok` boolean, required
  - `result` Poll, required — This object contains information about a poll.
    - `id` string, required — Unique poll identifier
    - `question` string, required — Poll question, 1-255 characters
    - `options` PollOption[], required — List of poll options
      - `text` string, required — Option text, 1-100 characters
      - `voter_count` integer, required — Number of users that voted for this option
    - `total_voter_count` integer, required — Total number of users that voted in the poll
    - `is_closed` boolean, required — True, if the poll is closed
    - `is_anonymous` boolean, required — True, if the poll is anonymous
    - `type` string, required — Poll type, currently can be “regular” or “quiz”
    - `allows_multiple_answers` boolean, required — True, if the poll allows multiple answers
    - `correct_option_id` integer — *Optional*. 0-based identifier of the correct answer option. Available only for polls in the quiz mode, which are closed, or was sent (not forwarded) by the bot or to the private chat with the bot.
    - `explanation` string — *Optional*. Text that is shown when a user chooses an incorrect answer or taps on the lamp icon in a quiz-style poll, 0-200 characters
    - `explanation_entities` MessageEntity[] — *Optional*. Special entities like usernames, URLs, bot commands, etc. that appear in the *explanation*
      - `type` 'mention' | 'hashtag' | 'cashtag' | 'bot_command' | 'url' | 'email' | 'phone_number' | 'bold' | 'italic' | 'underline' | 'strikethrough' | 'code' | 'pre' | 'text_link' | 'text_mention', required — Type of the entity. Can be “mention” (`@username`), “hashtag” (`#hashtag`), “cashtag” (`$USD`), “bot\_command” (`/start@jobs_bot`), “url” (`https://telegram.org`), “email” (`do-not-reply@telegram.org`), “phone\_number” (`+1-212-555-0123`), “bold” (**bold text**), “italic” (*italic text*), “underline” (underlined text), “strikethrough” (strikethrough text), “code” (monowidth string), “pre” (monowidth block), “text\_link” (for clickable text URLs), “text\_mention” (for users [without usernames](https://telegram.org/blog/edit#new-mentions))
      - `offset` integer, required — Offset in UTF-16 code units to the start of the entity
      - `length` integer, required — Length of the entity in UTF-16 code units
      - `url` string — *Optional*. For “text\_link” only, url that will be opened after user taps on the text
      - `user` User — This object represents a Telegram user or bot.
        - `id` integer, required — Unique identifier for this user or bot
        - `is_bot` boolean, required — True, if this user is a bot
        - `first_name` string, required — User's or bot's first name
        - `last_name` string — *Optional*. User's or bot's last name
        - `username` string — *Optional*. User's or bot's username
        - `language_code` string — *Optional*. [IETF language tag](https://en.wikipedia.org/wiki/IETF_language_tag) of the user's language
        - `can_join_groups` boolean — *Optional*. True, if the bot can be invited to groups. Returned only in [getMe](https://core.telegram.org/bots/api/#getme).
        - `can_read_all_group_messages` boolean — *Optional*. True, if [privacy mode](https://core.telegram.org/bots#privacy-mode) is disabled for the bot. Returned only in [getMe](https://core.telegram.org/bots/api/#getme).
        - `supports_inline_queries` boolean — *Optional*. True, if the bot supports inline queries. Returned only in [getMe](https://core.telegram.org/bots/api/#getme).
      - `language` string — *Optional*. For “pre” only, the programming language of the entity text
    - `open_period` integer — *Optional*. Amount of time in seconds the poll will be active after creation
    - `close_date` integer — *Optional*. Point in time (Unix timestamp) when the poll will be automatically closed

## Other responses

- `default`

---

[API](https://skmtc.net/stoplight/apis/telegram-bot-api.md) · [All operations](https://skmtc.net/stoplight/apis/telegram-bot-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/stoplight/telegram-bot-api/versions/be4bbb34b64a/schema)
