Trigger a bot using URL method
You can trigger a chatbot widget whose snippet code has been added via the plugin using the following method. You simply need to add #collectchat to any link or button from which the user may wish to interact with the bot. For example:
<a href="#collectchat">Open Chat</a>
Make sure the snippet code of the chatbot you want to open is added in the plugin settings.
![](https://uploads.help.center/641ae46f59722e0ef4ac6653/notion/GZmX5YNbjBDCm-ltbozlU.png)
Tip
You may choose to completely hide the bot as well. For this, go to Settings > Behaviour and select Custom Button Only for Widget.
![](https://uploads.help.center/641ae46f59722e0ef4ac6653/notion/SzaUpSkdi3_mV09fFqjUR.png)
This way user will only see the chatbot launcher and widget when the link with #collectchat is clicked via a link or button on the page.
You can add the link to your WordPress Menu as shown in the below screenshot. First, add a Custom Link and provide #collectchat as the URL value.
![](https://uploads.help.center/641ae46f59722e0ef4ac6653/notion/ZIsZb89TM6YhEOw3S-Zne.png)
This way, when user clicks on the WordPress Menu item, "Talk to Customer Care", the bot will be opened.
![](https://uploads.help.center/641ae46f59722e0ef4ac6653/notion/oQZr2UenonQq4WVROa1HB.png)
Trigger a new bot using URL method
Let's say you want to load a different chatbot on the same page on WordPress. For this you use the following URL method:
<a href="#5c75363e7744836a0231a584@collectchat">Open Chat</a>
This takes the form #<BotID>@collectchat. You need to grab the bot id of the bot you want to load for this method. The settings for WordPress menu item will look as follows.
![](https://uploads.help.center/641ae46f59722e0ef4ac6653/notion/adeZxCECuM78UiF7XPc5J.png)
Still need help?
Contact us