Note that the Inline Menu data type falls under the Message data type.
Menu
Each Menu consists of a set of rows. At least one row should be defined.
Field | Type | Required | Description |
---|---|---|---|
menu_ref | String | Yes | Unique identifier of this Menu as defined by bot. |
rows | Array of Row | Yes | Rows belong to this menu. Row which is an Array of buttons |
Row
Each row belongs to one keypad menu that composes of set of buttons. At least one button should be defined.
Field | Type | Required | Description |
---|---|---|---|
buttons | Array of Button | Yes | Button belongs to the row. |
row_order | Integer | Yes | Row order in the menu. |
Button
This object represents the button for replying. The button must have a button_callback which is the unique identifier defined by bot.
Field | Type | Required | Description |
---|---|---|---|
button_callback | String | Yes | This is unique identifier as defined by bot. The button_callback returned in inlineMessageCallback and ChatMenuCallback when button pressed. |
next_menu | Menu | Optional | Menu unique identifier that reference the next menu to navigate to it when the button pressed. |
button_span | Integer | Optional | Button Span |
button_order | Integer | Optional | The number of button order by ascending |
button_text_color | String | Optional | Text color of the button Title The color should be in hexadecimal format (Hex triplet ) or according to its common English name. Example : Red color can be set as "RED" or "#FF0000" |
button_bgColor | String | Optional | Button background color. The color should be in hexadecimal format (Hex triplet ) or according to its common English name. Example : Red color can be set as "RED" or "#FF0000" |
button_label | String | Optional | Button label or title. |
button_url | String | Optional | Button URL. When button pressed, an external URL link will be opened. |
button_query | String | Optional | Field used to query information from app, this can take one of two values as follows Location: to ask user to get location or point of map information. Contact : to ask user to get his contact number. |
chat | Chat | Optional | Chat is a unique identifier that references the specific channel or group to be opened when button is pressed. The user should be a member of the specified channel or group. If button_url and chat are both defined, both will be executed. |
nav_type | String | Optional | -Null is default to show navigation button for channel, group or contact-Type "admin" for show admin navigation button in chat setting. |
ButtonQueryResult
This object represents an incoming button query result from a callback button
Field | Type | Required | Description |
---|---|---|---|
latitude | String | Optional | Only sent in case of buttonQuery is location |
longitude | String | Optional | Only sent in case of buttonQuery is location |
contact | String | Option | Only sent in case of buttonQuery is phone_number. |
Read more in the inline menu topic here