This template allows your customers to easily return an item they bought in your online store.
After your customer chooses which item they want to return, the bot asks for the reason why they are returning the item (e.g., wrong size or color), generating valuable customer feedback. Additionally, based on the reason for return, the bot will offer them the option to order an alternative item that does meet their requirements.
The template uses a sneaker store as an example, but it can of course be customised to fit any type of online store. Keep reading to learn how you can customise this template for your own organisation.
This template uses two third party services:
- 1.Airtable, as a database for customer orders
- 2.Google Maps API, for finding the nearest post office
To let your bot interact with these services you will need an API key for each and configure these in the Action dialogs where the bot makes the API calls.
Below is an overview of the key dialogs in each flow of the bot. Here we will walk you through how to configure the connection with the Airtable and Google Maps APIs, as well as some other tips to customise this template for your business.
Modify the text in this dialog so it reflects the branding of your own business. Replace The Sneaker Store by the name of your business.
If your bot is capable of handling other use cases besides returns, introduce them to the user here.
In this dialog under the Talk to Human subflow, replace the email address by your business’ own support email address.
This dialog is the start of the Returns flow and is triggered by the
This intent has been trained to detect both the item the customer wants to return and their reason for returning it in their message. For example, the customer might say: "I want to return my Stan Smiths because they're too small" The bot will then recognise Stan Smith and too small as the
@reason_returnentities respectively and save them to variables of the same name. This way the bot won't have to ask again for this information later on in the conversation.
In this flow we ask for the customer’s email address and last four digits of their credit card as authentication to look up their past orders. If you want to authenticate your customer in another manner, replace these dialogs by your authentication method of choice. When you first imported this template, the dialogs will suggest you use [email protected] as email address and 6789 as credit card digits to authenticate. You can use these credentials to test the template with the sample order data, before connecting the bot to business' own orders database. You should remove these suggestions when you're ready to publish your bot.
After the user has given their email address and last 4 digits of their credit card, this dialog will look up their orders in an external database. By default, this template will look up the orders in an Airtable using the Search Record function of our Airtable integration.
You will need to customise this dialog by connecting it to your own Airtable account and your own Airtable base. However, when you have newly imported the Returns template, it will be linked to this Airtable. The order data is in the Orders table. Feel free to use it as an example of what the data in your own Airtable should look like, but make sure to replace it once you start using the bot for your own organisation.
If you do not yet have an Airtable account set up in Chatlayer, you can do so by clicking Connect new account and following the steps in the pop-up window. You will need your Airtable API key for this, which you can find on your Airtable account page.
Once you have set up your own Airtable base, head back to the dialog in Chatlayer. In the Base field replace the ID of the example Airtable base with the ID of your own Airtable base. In the Table field replace the example ID with the ID or name of the table in your own Airtable base where you store the order data. You can find your Airtable's base ID and table IDs here, or in the URL of your table view.
This action dialog changes the return status of the item to be returned in Airtable with the Update Record function. As in the Look up orders dialog, you will need to connect to your own Airtable account and replace the example base and table IDs by your own.
This dialog also sends an email to the customer with their return label. Change the destination address in the return label to your own business’ address.
If the user is returning their item because they don’t like the color, this dialog will look in the Airtable database if it is available in other colors. In our example Airtable base, you will find these other colors in the catalog table. As in the other Airtable integration dialogs, you will need to connect to your own Airtable account and replace the example base and table IDs by your own.
After the user has given the details for their replacement order, this dialog adds the new order in the new_orders table in Airtable using the Create Record function. Like in the other Airtable integration dialogs, you will need to connect to your own Airtable account and replace the example base and table IDs by your own.
After the order has been added in Airtable, you should also add a payment link to the record for the new order in the payment_link field. You can do this by creating a Zapier integration that automatically creates a payment link with your payment provider (for example Stripe) once a new record is added in Airtable, and then adds that automatically adds then payment link in Airtable. You can find more info on how to use Zapier here. Alternatively you can also create a custom integration directly in Chatlayer with your business’ payment provider to generate a payment link and add it to your Airtable.
With this flow, your customers can find the post office closest to their delivery address. The functionality of this flow is the same as the Find nearest location pre-built flow template. To find out how to customise this flow, you can consult the tutorial for that flow template here.
In addition to changing the flows, you will also need to make some changes to the entities in the NLP section of your bot. The contextual entity
@modeland the match entity
@model_matchcapture the products available in the online store. You will need to replace the example values by the names of the products in your own store.
If you want to offer your bot in other languages than English and Dutch you will also need to add the ISO 639-1 code for that language as a value in the contextual entity