answerWebAppQuery#

Returns: SentWebAppMessage

class aiogram.methods.answer_web_app_query.AnswerWebAppQuery(*, web_app_query_id: str, result: aiogram.types.inline_query_result.InlineQueryResult, **extra_data: Any)[source]#

Use this method to set the result of an interaction with a Web App and send a corresponding message on behalf of the user to the chat from which the query originated. On success, a aiogram.types.sent_web_app_message.SentWebAppMessage object is returned.

Source: https://core.telegram.org/bots/api#answerwebappquery

web_app_query_id: str#

Unique identifier for the query to be answered

result: aiogram.types.inline_query_result.InlineQueryResult#

A JSON-serialized object describing the message to be sent

build_request(bot: Bot) Request[source]#

Usage#

As bot method#

result: SentWebAppMessage = await bot.answer_web_app_query(...)

Method as object#

Imports:

  • from aiogram.methods.answer_web_app_query import AnswerWebAppQuery

  • alias: from aiogram.methods import AnswerWebAppQuery

With specific bot#

result: SentWebAppMessage = await bot(AnswerWebAppQuery(...))

As reply into Webhook in handler#

return AnswerWebAppQuery(...)