Class InlineKeyboardButtonType.
| see | |
|---|---|
| package | Default |
create(string $text, array|null $data = null) : \TgBotApi\BotApiBase\Type\InlineKeyboardButtonType
string
arraynull
\TgBotApi\BotApiBase\Exception\BadArgumentException |
|---|
\TgBotApi\BotApiBase\Type\InlineKeyboardButtonTypefill(array $data, array $forbidden = array())
array
array
\TgBotApi\BotApiBase\Exception\BadArgumentException |
|---|
$callbackData : string | null
$callbackGame : \TgBotApi\BotApiBase\Type\CallbackGameType | null
NOTE: This type of button must always be the first button in the first row.
$loginUrl : \TgBotApi\BotApiBase\Type\LoginUrlType
Can be used as a replacement for the Telegram Login Widget.
$pay : boolean | null
NOTE: This type of button must always be the first button in the first row.
$switchInlineQuery : string | null
Can be empty, in which case just the bot’s username will be inserted.
Note: This offers an easy way for users to start using your bot in inline mode when they are currently in a private chat with it. Especially useful when combined with switch_pm… actions – in this case the user will be automatically returned to the chat they switched from, skipping the chat selection screen.
$switchInlineQueryCurrentChat : string | null
This offers a quick way for the user to open your bot in inline mode in the same chat – good for selecting something from multiple options.
$text : string
$url : string | null