pub struct EditMessageCaptionRequest<'a> { /* private fields */ }Expand description
Use this method to edit captions of messages. On success, if the edited message is not an inline message, the edited Message is returned, otherwise True is returned. Note that business messages that were not sent by the bot and do not contain an inline keyboard can only be edited within 48 hours from the time they were sent.
Implementations§
Source§impl<'a> EditMessageCaptionRequest<'a>
impl<'a> EditMessageCaptionRequest<'a>
pub fn new(api: &'a API) -> Self
Sourcepub fn business_connection_id(
self,
business_connection_id: impl Into<String>,
) -> Self
pub fn business_connection_id( self, business_connection_id: impl Into<String>, ) -> Self
Unique identifier of the business connection on behalf of which the message to be edited was sent
Sourcepub fn chat_id(self, chat_id: impl Into<ChatId>) -> Self
pub fn chat_id(self, chat_id: impl Into<ChatId>) -> Self
Required if inline_message_id is not specified. Unique identifier for the target chat or username of the target channel (in the format @channelusername)
Sourcepub fn message_id(self, message_id: impl Into<i64>) -> Self
pub fn message_id(self, message_id: impl Into<i64>) -> Self
Required if inline_message_id is not specified. Identifier of the message to edit
Sourcepub fn inline_message_id(self, inline_message_id: impl Into<String>) -> Self
pub fn inline_message_id(self, inline_message_id: impl Into<String>) -> Self
Required if chat_id and message_id are not specified. Identifier of the inline message
Sourcepub fn caption(self, caption: impl Into<String>) -> Self
pub fn caption(self, caption: impl Into<String>) -> Self
New caption of the message, 0-1024 characters after entities parsing
Sourcepub fn parse_mode(self, parse_mode: impl Into<String>) -> Self
pub fn parse_mode(self, parse_mode: impl Into<String>) -> Self
Mode for parsing entities in the message caption. See formatting options for more details.
Sourcepub fn caption_entities(
self,
caption_entities: impl IntoIterator<Item = impl Into<MessageEntity>>,
) -> Self
pub fn caption_entities( self, caption_entities: impl IntoIterator<Item = impl Into<MessageEntity>>, ) -> Self
A JSON-serialized list of special entities that appear in the caption, which can be specified instead of parse_mode
Sourcepub fn show_caption_above_media(
self,
show_caption_above_media: impl Into<bool>,
) -> Self
pub fn show_caption_above_media( self, show_caption_above_media: impl Into<bool>, ) -> Self
Pass True, if the caption must be shown above the message media. Supported only for animation, photo and video messages.
Sourcepub fn reply_markup(self, reply_markup: impl Into<InlineKeyboardMarkup>) -> Self
pub fn reply_markup(self, reply_markup: impl Into<InlineKeyboardMarkup>) -> Self
A JSON-serialized object for an inline keyboard.
Trait Implementations§
Source§impl<'a> Clone for EditMessageCaptionRequest<'a>
impl<'a> Clone for EditMessageCaptionRequest<'a>
Source§fn clone(&self) -> EditMessageCaptionRequest<'a>
fn clone(&self) -> EditMessageCaptionRequest<'a>
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more