Search…
FAQs

How to...?

...start a conversation with a welcome / intro message?

You will need behavior rules and an outputset for that.
For the behavior rules, you have three possibilities (ordered by recommendation):

1) Match for the action CONVERSATION_START

1
{
2
"behaviorGroups": [
3
{
4
"name": "Onboarding",
5
"behaviorRules": [
6
{
7
"name": "Welcome",
8
"actions": [
9
"welcome"
10
],
11
"conditions": [
12
{
13
"type": "actionmatcher",
14
"configs": {
15
"actions": "CONVERSATION_START"
16
}
17
}
18
]
19
}
20
]
21
}
22
]
23
}
Copied!

2) check if the triggered action has never be triggered before

1
{
2
"behaviorGroups": [
3
{
4
"name": "Onboarding",
5
"behaviorRules": [
6
{
7
"name": "Welcome",
8
"actions": [
9
"welcome"
10
],
11
"conditions": [
12
{
13
"type": "actionmatcher",
14
"configs": {
15
"actions": "welcome",
16
"occurrence": "never"
17
}
18
}
19
]
20
}
21
]
22
}
23
]
24
}
Copied!

3) Check how often this rule has succeeded before.

1
{
2
"behaviorGroups": [
3
{
4
"name": "Onboarding",
5
"behaviorRules": [
6
{
7
"name": "Welcome",
8
"actions": [
9
"welcome"
10
],
11
"conditions": [
12
{
13
"type": "occurrence",
14
"configs": {
15
"maxTimesOccurred": "0",
16
"behaviorRuleName": "Welcome"
17
}
18
}
19
]
20
}
21
]
22
}
23
]
24
}
Copied!

Outputset:

1
{
2
"outputSet": [
3
{
4
"action": "welcome",
5
"timesOccurred": 0,
6
"outputs": [
7
{
8
"type": "text",
9
"valueAlternatives": [
10
{
11
"text": "Some output here...",
12
"delay": 3000
13
}
14
]
15
}
16
],
17
"quickReplies": [
18
// quickreplies here
19
]
20
}
21
]
22
}
Copied!

...say something based on what the bot previously said?

(Think of a form-like behavior, asking a couple of questions and sending these results somewhere.)

Check whether a certain action had been triggered in the previous conversation step.

1
{
2
"behaviorGroups": [
3
{
4
"name": "Onboarding",
5
"behaviorRules": [
6
{
7
"name": "Ask for Name",
8
"actions": [
9
"ask_for_name"
10
],
11
"conditions": [
12
{
13
"type": "actionmatcher",
14
"configs": {
15
"actions": "some_previous_action",
16
"occurrence": "lastStep"
17
}
18
}
19
]
20
}
21
]
22
}
23
]
24
}
Copied!
Have a question that is not covered? Drop us an email at [email protected], we are happy to enhance our documentation!
Last modified 1yr ago