code: def edit_caption(
          self,
          caption: str,
          parse_mode: str = "",
          reply_markup: Union[
              "pyrogram.InlineKeyboardMarkup",
              "pyrogram.ReplyKeyboardMarkup",
              "pyrogram.ReplyKeyboardRemove",
              "pyrogram.ForceReply"
          ] = None
      ) -> "Message":
          
          return self._client.edit_message_caption(
              chat_id=self.chat.id,
              message_id=self.message_id,
              caption=caption,
              parse_mode=parse_mode,
              reply_markup=reply_markup
          )
docs: Bound method *edit_caption* of :obj:`Message <pyrogram.Message>`
  
          Use as a shortcut for:
  
          .. code-block:: python
  
              client.edit_message_caption(
                  chat_id=message.chat.id,
                  message_id=message.message_id,
                  caption="hello"
              )
  
          Example:
              .. code-block:: python
  
                  message.edit_caption("hello")
  
          Args:
              caption (``str``):
                  New caption of the message.
  
              parse_mode (``str``, *optional*):
                  Use :obj:`MARKDOWN <pyrogram.ParseMode.MARKDOWN>` or :obj:`HTML <pyrogram.ParseMode.HTML>`
                  if you want Telegram apps to show bold, italic, fixed-width text or inline URLs in your message.
                  Defaults to Markdown.
  
              reply_markup (:obj:`InlineKeyboardMarkup`, *optional*):
                  An InlineKeyboardMarkup object.
  
          Returns:
              On success, the edited :obj:`Message <pyrogram.Message>` is returned.
  
          Raises:
              :class:`RPCError <pyrogram.RPCError>` in case of a Telegram RPC error.