Skip to content

addBotMediaPreview

Function · TDLib 1.8.67 · d1085f9c

Adds a new media preview to the beginning of the list of media previews of a bot. Returns the added preview after addition is completed server-side. The total number of previews must not exceed getOption("bot_media_preview_count_max") for the given language

addBotMediaPreview(
  bot_user_id: int53,
  language_code: string,
  content: InputStoryContent
) → BotMediaPreview

bot_user_id

int53

Identifier of the target bot. The bot must be owned and must have the main Web App

language_code

string

A two-letter ISO 639-1 language code for which preview is added. If empty, then the preview will be shown to all users for whose languages there are no dedicated previews. If non-empty, then there must be an official language pack of the same name, which is returned by getLocalizationTargetInfo

content

InputStoryContent

Content of the added preview