• Edit message text, media, reply markup and schedule date.

    Parameters

    • client: ITelegramClient
    • params: InputMessageId & {
          businessConnectionId?: string;
          disableWebPreview?: boolean;
          invertMedia?: boolean;
          media?: InputMediaLike | undefined;
          progressCallback?: (uploaded: number, total: number) => void;
          replyMarkup?: ReplyMarkup | undefined;
          scheduleDate?: number | Date;
          shouldDispatch?: true;
          text?: InputText | undefined;
      }
      • OptionalbusinessConnectionId?: string
      • OptionaldisableWebPreview?: boolean

        Whether to disable links preview in this message

      • OptionalinvertMedia?: boolean

        Whether to invert media position.

        Currently only supported for web previews and makes the client render the preview above the caption and not below.

      • Optionalmedia?: InputMediaLike | undefined

        New message media

      • OptionalprogressCallback?: (uploaded: number, total: number) => void

        For media, upload progress callback.

      • OptionalreplyMarkup?: ReplyMarkup | undefined

        For bots: new reply markup. If omitted, existing markup will be removed.

      • OptionalscheduleDate?: number | Date

        To re-schedule a message: new schedule date. When passing a number, a UNIX time in ms is expected.

      • OptionalshouldDispatch?: true

        Whether to dispatch the edit message event to the client's update handler.

      • Optionaltext?: InputText | undefined

        New message text

        When media is passed, media.caption is used instead

    Returns Promise<Message>