Back to Blog

Create quick replies in cloude code actions

Quick replies are buttons that you can add to a reply to improve the Customer Experience. You can add quick replies in the “Flows” section or within cloud code actions. This article will focus on adding quick replies by using actions.

Quick replies in Cloud Code Actions

The following code is an example of a text with two quick reply buttons.


async payload => {

  const text = new Text('We have a 40" screen for sale. Want to preorder it?')
  text.addQuickReply(new QuickReply({
    label: '👍',
    value: 'Yes'
  }))
  text.addQuickReply(new QuickReply({
    label: '👎',
    value: 'No'
  }))

  const message = new Message('Fallback text').addResponse(text)

  return message
}
Get StartedContact us