telebot-ts API Documentation - v1.0.0
    Preparing search index...

    Class InlineKeyboardButton

    A single button on an InlineKeyboardMarkup.

    A class-based alternative to the InlineKeyboard fluent builder, for developers who prefer constructing keyboards as nested rows of InlineKeyboardButton instances passed to InlineKeyboardMarkup. Both styles produce the same InlineKeyboardMarkup shape (a plain object literal shaped like InlineKeyboardButton works too) and can be freely mixed.

    const keyboard = new InlineKeyboardMarkup([
    [
    new InlineKeyboardButton("Option 1", { callback_data: "opt_1" }),
    new InlineKeyboardButton("Option 2", { callback_data: "opt_2" }),
    ],
    [new InlineKeyboardButton("Website", { url: "https://example.com" })],
    ]);

    Implements

    Index
    callback_data?: string

    Data to be sent in a callback query to the bot when the button is pressed (1-64 bytes).

    callback_game?: CallbackGame

    Description of the game that will be launched when the user presses the button.

    copy_text?: CopyTextButton

    Description of the button that copies the specified text to the clipboard.

    disabled?: DisabledButton

    If set, then the button is disabled and does nothing (Bot API 10.3+).

    icon_custom_emoji_id?: string

    Unique identifier of the custom emoji shown before the text.

    login_url?: LoginUrl

    An HTTPS URL used to automatically authorize the user.

    pay?: boolean

    true to send a Pay button; must be the first button of the first row.

    style?: string

    Style of the button.

    switch_inline_query?: string

    If set, pressing the button prompts the user to insert the specified inline query.

    switch_inline_query_chosen_chat?: SwitchInlineQueryChosenChat

    If set, pressing the button prompts the user to select a chat of the specified type.

    switch_inline_query_current_chat?: string

    If set, pressing the button inserts the specified inline query in the current chat.

    text: string

    Label text on the button.

    url?: string

    HTTP or tg:// URL to be opened when the button is pressed.

    web_app?: WebAppInfo

    Description of the Web App that will be launched when the user presses the button.