6. Test your bot

The best way to check if the bot you're building is doing what you expect is to contantly test every new development. Here's more information about it.

The fastest way to test your bot is the 'Test your bot' widget in the bottom right corner.

When you click it, a pane will open on the right side of the screen and you can choose how to test your bot. So far there are three options:

  1. Debugger: showcases how your bot will behave in a web chat. More information here.

  2. Voice: allows you to listen and speak to your bot, if it was designed for a voice channel.

  3. WhatsApp Sandbox: enables you to test your bot on a real WhatsApp channel.

Voice

You can test your voice bots by selecting the Voice option in the 'Test your bot' section. You can interact with your bot by clicking the red button with a microphone icon in it. Once you click it, you will hear the first bot message and be able to reply to it by talking.

You will be asked to allow microphone access, if not, follow the instructions on the camera sign at the right extremity of your browser bar. You can read more about it on Google, Mozilla, Safari.

We recommend using headphones when testing voice on your computer to prevent the bot from interpreting its own echo as a user response.

WhatsApp Sandbox

When you select the WhatsApp Sandbox option, you will see a QR code. By scanning it with your phone or clicking the 'click here' link under it, you will be redirected to WhatsApp.

WhatsApp will open a new conversation with the Sandbox and a message will be pre-filled. This message will contain the ID of the bot you want to contact. As soon as you send the pre-filled message, your WhatsApp number will be connected to that bot for the next 72h, or until you send 'STOP'.

After connecting to your bot through the Sandbox, send a message to trigger it:

To disconnect from one bot and test another, send "STOP". You will receive a message confirming that your number was disconnected from that bot. You can connect to a different bot by sending another bot ID, for example "join xyz1234".

The commands to connect or disconnect your number to/from a bot are case sensitive.

Last updated