Calculations and variables

Expected completion 20 minutes.

This session is optional, as not every bot you build will need to perform calculations. But, it is a handy feature that allows you to automate even more tasks with Josef.

You can build calculations and use them across the platform the same way as responses are used, including inserting them in documents, notifications, messages and using them when creating rules. 

Variables library

The Variables library shows an overview of all of your bot’s response and calculation variables. This is also where you can add or edit a calculation. The Variables library can be found as a tag in the flowchart, list view, notification page or as a button in the Word editor.

Challenge yourself!

If you’re here in this optional section, we thought you may be looking for a challenge! So, this session works a little bit differently to the previous sessions. Rather than show you a video that tells you how to add a calculation to our example bot, the video below gives you a general overview of calculations and variables and teaches you how to create a calculation on another example bot.

Once you’ve learned how to create a calculation, consider where you could use them to improve the intake bot we’ve built during this module. This is your chance to get creative! There are many different possible use cases for calculations. Here’s a few to help spark your bot building creativity:

  • Calculate the end date of an agreement
  • Calculate a due date
  • Calculate a salary bonus
  • Calculate a tax rate

Now, watch the video below to learn how to create a calculation.

Practical task

Test your understanding of calculations by completing the following tasks:

  1. Create a calculation;
  2. Insert the calculation in a message, document or notification;
  3. Use the calculation in a rule.
  4. Test your bot to see if your calculation works!

Hint: you will have to add some additional messages to your bot to create the calculation!

Want to see what we came up with? Watch the video below to see the calculation we added to the bot. But, don’t spoil the fun by watching before you’ve had a chance to try it out yourself!

Try out the calculation now in the intake bot we built throughout this module below.