https://discord.gg/botpress logo
Add Button Card to Standard Nodes in Botpress
# 👀feature-requests
f
Currently, there is no Button Card available in Standard Nodes, even though other message types defined in the Autonomous Node (AN) Prompt have corresponding cards. When using an AN, it can generate clickable buttons that, when clicked, send a message containing the button text. However, there is no equivalent way to add these buttons in Standard Nodes. This feature request is for adding a Button Card in Standard Nodes that allows adding non-blocking, optional buttons. These buttons should behave like the ones generated by AN—when clicked, they should simply send a message with the button text, but they should not block the conversation or force user input. Use Case: - Allowing Standard Nodes to suggest messages via buttons without requiring user input. - Letting users click buttons at any time instead of typing, while still keeping the conversation fluid. - Not blocking the flow (unlike a capture card). - Matching the behavior of AN-generated buttons but with manual control inside Standard Nodes. This would improve flexibility and provide a consistent experience across Botpress features, making it easier to guide users without forcing interactions. Additional Considerations: What the AN has in its global prompt indicates there are different types of actions ('say' | 'url' | 'postback')
Copy code
#### **Button**

- Use `<Button>` to offer quick replies displayed as buttons to the user.

  **Props**:

  - `action: 'say' | 'url' | 'postback'`
  - `label: string` (required, min 1 character, max 250 characters)
  - `value?: string` The postback to send when button is clicked (required if action = postback)
  - `url?: string` The URL to open when button is clicked (required if action = url)

  **Children**: A `<Button>` cannot have children.
'''
  yield <Message>
    Please choose an option:
    <Button action='say' label="Option 1" />
    <Button action='postback' label="Option 2" value="option_two" />
  </Message>
'''
@bumpy-butcher-41910 Added!
w
I think there are instructions to use a single choice
b
Was going to say the same. It works well enough, the purpose of a button is to route on click. Single choice/ 1 option works. But also should be a unique card.
f
A single choice is blocking. I need something that is not blocking.
4 Views