cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Flow Designs: Set Business Hours

Flow Designs: Set Business Hours

When designing your chatbot you might encounter the fact that your business processes are different outside of business hours. A common example is a livechat takeover by a human during business hours. Outside of business hours you might want to get contact details of the end user to get back to them asap.

Set Business Hours

You can set your Business Hours by selecting Business Hours from the Project Settings. You will be asked to enter a Label, Timezone, Channel and your opening hours.

 

bh1.png

 

Conditions or Actions

From here we got two options. You can either use conditions if you feel more confortable with the drag & drop interface or you could you Actions if you prefer Javascript.

Conditions

Conditions in combination with Business Hours can be used to alter the chatbot flow based on your business hours. Use conditions or if/else statements, and branch your chatbot. If it its within opening hours we can follow up with a live agent. Else, we create a ticket to follow up with a CRM system.

 

bh2.png

 

Actions

After setting your business hours, you can also branch your bot by using Actions. Actions are small pieces of JavaScript that you can run within a Flow. The example below triggers the event "Livechat Open" if it is within Business Hours and triggers the event "Livechat Closed" otherwise. Change the label to your own label and modify the triggered event to your needs.

After you've created your action don't forget to implement it in your design. Within your flows drag en drop an Action reply and select the action you've just created.

async payload => {

 if(await toolbelt.isBusinessHours({
   label: "YourLabel"
 })) {
   trigger('Livechat Open')
 }
 else{
   trigger('Livechat Closed')
 }
}
Labels (1)

Flow Designs: Set Business Hours

When designing your chatbot you might encounter the fact that your business processes are different outside of business hours. A common example is a livechat takeover by a human during business hours. Outside of business hours you might want to get contact details of the end user to get back to them asap.

Set Business Hours

You can set your Business Hours by selecting Business Hours from the Project Settings. You will be asked to enter a Label, Timezone, Channel and your opening hours.

 

bh1.png

 

Conditions or Actions

From here we got two options. You can either use conditions if you feel more confortable with the drag & drop interface or you could you Actions if you prefer Javascript.

Conditions

Conditions in combination with Business Hours can be used to alter the chatbot flow based on your business hours. Use conditions or if/else statements, and branch your chatbot. If it its within opening hours we can follow up with a live agent. Else, we create a ticket to follow up with a CRM system.

 

bh2.png

 

Actions

After setting your business hours, you can also branch your bot by using Actions. Actions are small pieces of JavaScript that you can run within a Flow. The example below triggers the event "Livechat Open" if it is within Business Hours and triggers the event "Livechat Closed" otherwise. Change the label to your own label and modify the triggered event to your needs.

After you've created your action don't forget to implement it in your design. Within your flows drag en drop an Action reply and select the action you've just created.

async payload => {

 if(await toolbelt.isBusinessHours({
   label: "YourLabel"
 })) {
   trigger('Livechat Open')
 }
 else{
   trigger('Livechat Closed')
 }
}
Labels (1)
Last Reviewed:
03-13-2022 03:12 PM

Flow Designs: Set Business Hours

When designing your chatbot you might encounter the fact that your business processes are different outside of business hours. A common example is a livechat takeover by a human during business hours. Outside of business hours you might want to get contact details of the end user to get back to them asap.

Set Business Hours

You can set your Business Hours by selecting Business Hours from the Project Settings. You will be asked to enter a Label, Timezone, Channel and your opening hours.

 

bh1.png

 

Conditions or Actions

From here we got two options. You can either use conditions if you feel more confortable with the drag & drop interface or you could you Actions if you prefer Javascript.

Conditions

Conditions in combination with Business Hours can be used to alter the chatbot flow based on your business hours. Use conditions or if/else statements, and branch your chatbot. If it its within opening hours we can follow up with a live agent. Else, we create a ticket to follow up with a CRM system.

 

bh2.png

 

Actions

After setting your business hours, you can also branch your bot by using Actions. Actions are small pieces of JavaScript that you can run within a Flow. The example below triggers the event "Livechat Open" if it is within Business Hours and triggers the event "Livechat Closed" otherwise. Change the label to your own label and modify the triggered event to your needs.

After you've created your action don't forget to implement it in your design. Within your flows drag en drop an Action reply and select the action you've just created.

async payload => {

 if(await toolbelt.isBusinessHours({
   label: "YourLabel"
 })) {
   trigger('Livechat Open')
 }
 else{
   trigger('Livechat Closed')
 }
}
Labels (1)
Version history
Last update:
‎06-19-2021 01:19 PM
Updated by:
Contributors