Skip to content

Keybord problem #23

@luciuz

Description

@luciuz

Hi!
When I'm trying send message with inlineKeyboard (using reply_markup).

...
$buttons[] = [new InlineKeyboardButton([
                'text' => $route->name,
                'callback_data' => $route->id
            ])];
...
'reply_markup' => new InlineKeyboardMarkup(['inline_keyboard' => $buttons])
...

I'm getting an error

Code: 400. Description: "Bad Request: can't parse inline keyboard button: Field "url" must be of type String

Coz reply_markup contains all params including empty url and switch_inline_query

[reply_markup] => {"inline_keyboard":[[{"text":"Www","url":null,"callback_data":1,"switch_inline_query":null}]]}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions