pyrobale.objects.replykeyboardmarkup

Classes

ReplyKeyboardMarkup

Represents a reply keyboard.

Module Contents

class pyrobale.objects.replykeyboardmarkup.ReplyKeyboardMarkup(*args, remove_keyboard=False)[source]

Represents a reply keyboard.

Parameters:

remove_keyboard (bool, optional) – If True, the keyboard will be removed. Defaults to False.

Each dictionary contains the following keys
  • keyboard (list): A list of lists of dictionaries representing the buttons in the keyboard.

  • text (str): The text of the button.

  • request_contact (bool, optional): If True, the user’s phone number will be sent.

  • request_location (bool, optional): If True, the user’s location will be sent.

  • web_app (WebApp, optional): The web app associated with the button.

remove_keyboard = False[source]
keyboard = [][source]
add_button(text, request_contact=None, request_location=None, web_app=None)[source]

Add a button to the current row.

Parameters:
add_row()[source]

Add a new row for buttons.

to_dict()[source]

Convert to a dictionary.

property json[source]
__str__()[source]