Action
Action Schema
There are actions for the bot to take when a user interact with a controller associated with the action
Common Properties
These are common properties for all type of actions
Field
Required
Type
Description
Restriction
label
false*
String
Label for the action
is required for Message of type
Button TemplateandCarousel Templateand quick reply object.Maximum character is 20
area
false*
Object
area of the action (see Area Object below)
is required for Message of type imagemap
Area Object
Field
Required
Type
Description
Restriction
x
true
Integer
Horizontal position relative to the left edge of the area
Value must be 0 or higher.
y
true
Integer
Vertical position relative to the top of the area
Value must be 0 or higher.
width
true
Integer
Width of the tappable area
height
true
Integer
Height of the tappable area
Action Types
There are 5 types of actions.
Message Action
When a message action is prompted, a string in field text will be sent as a message from the user
Field
Required
Type
Description
Restriction
type
true
String
Required as message
text
true
String
Text sent when the action is performed
Example
Postback Action
When a postback action is prompted, a postback event is returned via webhook
Field
Required
Type
Description
Restriction
type
true
String
Required as postback
data
true
String
String returned via webhook
text
false
String
Text displayed in the chat as a message sent by the user when the action is performed
Example
Workflow Template Action
When a control associated with this action is tapped, a workflow template will be prompted to the user
Field
Required
Type
Description
Restriction
type
true
String
Required as workflowTemplate
templateId
true
Stringe
workflow template ID
Example
Workflow Action
When a control associated with this action is tapped, the workflow will be prompted to the user
Field
Required
Type
Description
Restriction
type
true
String
Required as workflow
workflowId
true
String
The user's workflow ID
Example
Workflows Action
When a control associated with this action is tapped, the user will be redirect to the Workflows page.
Field
Required
Type
Description
Restriction
type
true
String
Required as workflows
status
false
String
The workflow status, used to filter the Workflows
'awaiting', 'processing', 'completed', 'rejected', 'canceled'
Library Action
When a control associated with this action is tapped, the user will be redirect to the corresponding Library document.
Example
URI Action
When a control associated with this action is tapped, the URI specified in the linkUri property is opened.
Field
Required
Type
Description
Restriction
type
true
String
Required as uri
linkUri
true
Stringe
URI opened when the action is performed
Example
Last updated