telegram api method · layer 229 · #c0cf7646

messages.sendInlineBotResult

usable by users

Send a result obtained using messages.getInlineBotResults.

definition

messages.sendInlineBotResult#c0cf7646 flags:# silent:flags.5?true background:flags.6?true clear_draft:flags.7?true hide_via:flags.11?true peer:InputPeer reply_to:flags.0?InputReplyTo random_id:long query_id:long id:string schedule_date:flags.10?int send_as:flags.13?InputPeer quick_reply_shortcut:flags.17?InputQuickReplyShortcut allow_paid_stars:flags.21?long = Updates;

parameters

nametypedescription
flags#Flags, see TL conditional fields
silentflags.5?trueWhether to send the message silently (no notification will be triggered on the other client)
backgroundflags.6?trueWhether to send the message in background
clear_draftflags.7?trueWhether to clear the draft
hide_viaflags.11?trueWhether to hide the via @botname in the resulting message (only for bot usernames encountered in the config)
peerInputPeerDestination
reply_toflags.0?InputReplyToIf set, indicates that the message should be sent in reply to the specified message or story.
random_idlongRandom ID to avoid resending the same query
query_idlongQuery ID from messages.getInlineBotResults
idstringResult ID from messages.getInlineBotResults
schedule_dateflags.10?intScheduled message date for scheduled messages
send_asflags.13?InputPeerSend this message as the specified peer
quick_reply_shortcutflags.17?InputQuickReplyShortcutAdd the message to the specified quick reply shortcut », instead.
allow_paid_starsflags.21?longFor paid messages », specifies the amount of Telegram Stars the user has agreed to pay in order to send the message.

returns

Updates

errors (43)

codeerrordescription
400BUSINESS_CONNECTION_NOT_ALLOWEDThis method was invoked over a business connection using invokeWithBusinessConnection, but either (1) we're a user, and users cannot invoke methods over a business connection; (2) we're a bot, but business mode was disabled in @botfather or (3); we're a bot, but this method cannot be invoked over a business connection.
400CHANNEL_INVALIDThe provided channel is invalid.
400CHANNEL_PRIVATEYou haven't joined this channel/supergroup.
400CHAT_ADMIN_REQUIREDYou must be an admin in this chat to do this.
400CHAT_RESTRICTEDYou can't send messages in this chat, you were restricted.
400CHAT_SEND_INLINE_FORBIDDENYou can't send inline messages in this group.
400ENTITY_BOUNDS_INVALIDA specified entity offset or length is invalid, see here » for info on how to properly compute the entity offset/length.
400INLINE_RESULT_EXPIREDThe inline query expired.
400INPUT_USER_DEACTIVATEDThe specified user was deleted.
400MEDIA_EMPTYThe provided media object is invalid.
400MSG_ID_INVALIDInvalid message ID provided.
400PEER_ID_INVALIDThe provided peer id is invalid.
400QUERY_ID_EMPTYThe query ID is empty.
400QUICK_REPLIES_TOO_MUCHA maximum of appConfig.`quick_replies_limit` shortcuts may be created, the limit was reached.
400REPLY_MESSAGES_TOO_MUCHEach shortcut can contain a maximum of appConfig.`quick_reply_messages_limit` messages, the limit was reached.
400RESULT_ID_EMPTYResult ID empty.
400RESULT_ID_INVALIDOne of the specified result IDs is invalid.
400SCHEDULE_DATE_TOO_LATEYou can't schedule a message this far in the future.
400SCHEDULE_TOO_MUCHThere are too many scheduled messages.
400SEND_AS_PEER_INVALIDYou can't send messages as the specified peer.
400TOPIC_DELETEDThe specified topic was deleted.
400USER_BANNED_IN_CHANNELYou're banned from sending messages in supergroups/channels.
400VOICE_MESSAGES_FORBIDDENThis user's privacy settings forbid you from sending voice messages.
400WEBPAGE_CURL_FAILEDFailure while fetching the webpage with cURL.
400WEBPAGE_MEDIA_EMPTYWebpage media empty.
400YOU_BLOCKED_USERYou blocked this user.
401AUTH_KEY_UNREGISTEREDThe specified authorization key is not registered in the system (for example, a PFS temporary key has expired).
403ALLOW_PAYMENT_REQUIRED_%dThis peer charges %d Telegram Stars per message, but the allow_paid_stars was not set or its value is smaller than %d.
403CHAT_GUEST_SEND_FORBIDDENYou join the discussion group before commenting, see here » for more info.
403CHAT_SEND_AUDIOS_FORBIDDENYou can't send audio messages in this chat.
403CHAT_SEND_GAME_FORBIDDENYou can't send a game to this chat.
403CHAT_SEND_GIFS_FORBIDDENYou can't send gifs in this chat.
403CHAT_SEND_INLINE_FORBIDDENYou can't send inline messages in this group.
403CHAT_SEND_MEDIA_FORBIDDENYou can't send media in this chat.
403CHAT_SEND_PHOTOS_FORBIDDENYou can't send photos in this chat.
403CHAT_SEND_PLAIN_FORBIDDENYou can't send non-media (text) messages in this chat.
403CHAT_SEND_STICKERS_FORBIDDENYou can't send stickers in this chat.
403CHAT_SEND_VOICES_FORBIDDENYou can't send voice recordings in this chat.
403CHAT_WRITE_FORBIDDENYou can't write in this chat.
403PRIVACY_PREMIUM_REQUIREDYou need a Telegram Premium subscription to send a message to this user.
420SLOWMODE_WAIT_%dSlowmode is enabled in this chat: wait %d seconds before sending another message to this chat.
500RANDOM_ID_DUPLICATEYou provided a random ID that was already used.
500SEND_MEDIA_INVALIDThe specified media is invalid.

history

present in layers 46–229 · constructor id changed 6×

idlayers
#b16e06fe46–104
#220815b0105–134
#7aa11297135–147
#d3fbdccb148–159
#f7bc68ba160–175
#3ebee86a176–199
#c0cf7646200–229