How to Make a Chatbot in Messenger: Main Benefits for Your Business

The classic scheme of communication of any business with a person has always been through the phone. If you needed a plumber, you called the service and ordered, or if you wanted pizza at three in the morning, you called too. The telephone was the main channel of communication and service to people. Further, with the advent of mobile phones, it was transformed into applications. First, there were help desks available through the browser, then there were smartphones with an endless number of applications that we download daily.

A huge number of applications on the phone lead to an inconvenience of use since for each separate restaurant or cinema, you need to open a separate application to contact the operator. This is where chatbots in messengers come to the rescue, which solves the issue of centralization, and now in the same application where you communicate with your loved ones, you can book a table for the evening in your favorite restaurant. What you need to create a chatbot in a messenger application and what are the benefits for your SaaS project, we will consider in this article.

8 Benefits of Chatbots for Businesses

With the advent of chatbots, there have been many changes in the business. Companies and customers are interested in this tool, but not always keep up with the updates in the industry. Let's look at why brands are implementing chatbots, what they are guided by when creating them, and how a chatbot can help a business.

  • Link openness is much higher than email.

  • Faster communication with the client (everyone is now hanging on social networks).

  • You definitely won't end up in spam.

  • People are pissed off by the red dots of an unread message, and they often open messenger to watch.

  • The chatbot can immediately reply to messages without delay in opening mail. Therefore, the client does not have time to "cool down" - efficiency is now winning.

  • During webinars, there are technical issues that are quickly resolved through the messenger.

  • Bot creates the illusion of personal communication with clients.

  • You can quickly pick up your chat history.

How Does a Chatbot Work?

80% of companies in the world have created chatbots or plan to use them in 2020, follows from data from Oracle, a leading American corporation, as it's the world's largest software developer. According to Facebook, from 2017 to 2018, the activity of correspondence using chatbots increased more than five times. The reason for the popularity of chatbots is obvious - they keep the user engaged, provide more reach, and reduce the amount of routine work dramatically.

Many experts say: "Make a chatbot - you will sell." But it's not that simple. A chatbot can sell, but if an unprepared person immediately clicks on your Facebook ad button, gets into the messenger and the chatbot writes to him: “Buy my socks. This is the price,” - this person will probably not buy anything.

The reason is not that he does not need the product - he went through an advertisement. It's just that the user is "undercooked" enough to buy from your chatbot.

What can a chatbot in messenger really do for SaaS?

  • Greet the customer;

  • Pull up answers by keywords;

  • Delayed mailing;

  • Answer questions, help choose programs, products;

  • Segment your audience;

  • Count discounts, promotions, test results, and so on, depending on the choice of the answer;

  • Sell to the person's preferences.

Building a Chatbot from Scratch

how to make a chatbot

This is the landscape of the chatbot industry, created by the American service KeyReply. It reflects the key market players and tools for developing bots. 

For comparison, we will consider several options for instant messengers in which you can create chatbots. For example, Viber chatbot technology:

  1. The client writes a message to the chat, which goes to the Viber server;

  2. Viber accesses your server via an HTTP request;

  3. Your server provides an accurate response to this, which goes back to the Viber server;

  4. The answer comes to the chat.

chatbot development

 

Why is it necessary to understand this scheme? Firstly, many clients think that when they create a chatbot in a messenger, it will immediately become super-smart and will answer any questions. This part depends entirely on your server. The logic of answers is built from the client's side and it depends only on you how many questions the chatbot can answer accurately. In this scheme, any messenger is just an intermediary.

The Step-by-step Guide to Creating a Chatbot

To create a bot, follow these steps:

  1. You need to have an active account in the messenger;

  2. Register with the local Admin Panel where chatbots are created;

  3. Fill out a questionnaire about the future bot. Usually, the questionnaire contains such fields as:

  • Account Image - community logo;

  • Account Name - the name that will be displayed in the header of the bot;

  • URI - by which the bot can be found.

  1. Obtaining a token to work with the messenger server, it will be used to authenticate the request to the messenger API.

  2. Setting up a web server and connecting an SSL certificate;

  3. Installing webhook, this action is performed once; Webhook reports the following data to the Viber server:

  • A server address and endpoint that will receive messages from clients;

  • A list of events that the server will listen to;

  • Token;

  1. Verification and publication of the chatbot.

What tricks you might face with chatbots for business

Сreating a chatbot in a messenger application, you need to understand the features of each and choose the one specifically that does not limit your possibilities as much as possible.

Be prepared for messenger platform limitations

Please note that each messenger has a number of technical limitations and if you are not ready for them, then you should seriously consider another chatbot option. For example, a ban from WhatsApp can be obtained for:

  • Sending a large number of messages at the same time. This is one of the main reasons when 100+ of the same messages fly from the number at the same time - WhatsApp algorithms calculate this easily.

  • Negative user reaction. If you are spamming, then 3-5 clicks on the "Complain" button are enough to block your number.

  • The client will work on any device with an internet connection and Docker support. For example, simple testing can be performed on a regular laptop. The minimum server requirements for the production environment are 250 GB SSD, 16 GB RAM, Quad-core CPU. 

In general, the database should be running on a separate physical server (not where the Coreapp and Webapp containers are located). The admissible delay in data transmission between this server and the computer is no more than a few milliseconds.

Viber has its own list of restrictions that you should pay attention to:

  • Messages can be sent to all users who are subscribed (the user subscribes when he sends the bot the first message)

  • The maximum size of a JSON response is 30kb

  • The bot can send the user up to 100 messages per hour, the message counter is reset after the user replies to the message

  • The ability to send bulk messages opens only upon application and approval from Viber account managers.

  • The maximum length of the list of recipients of a mass message is 300 people, each such request can be executed up to 500 times in 10 seconds

  • If the user fails to deliver the message, Viber will attempt to resend this message for 14 days.

How can you customize your chatbot for SaaS?

Information management

There is no need to count on the fact that you will have a chatbot that will understand any of your text, written as you like. Most chatbots are not equipped with such cool intelligence. The overwhelming majority is somewhat reminiscent of USSD menus in SMS only in an improved version.

To control the bot, you, as the bot creator, must assume some kind of scenario. The user needs to send a command to get the desired result from the bot. When the bot receives the command, it will process it and react according to the scenario you have set. But imagine that the user wrote a command with an error, the bot, in this case, should warn that the command is not recognized and ask to try again. This is not entirely convenient for the user, and he can go looking for another bot with similar capabilities. You can lose a potential client, that's not good.

how to build a chatbot from scratch

In this case, keyboards will help us. It just needs to be displayed to the user after the start of the dialogue with the bot, and when he clicks on the button he needs, the correct command you put in will be sent to the bot. In this case, we avoid possible mistakes, the bot interface looks more welcoming and professional. The quality of the bot is improved.

benefits of chatbots

With each message, the bot can send a different set of buttons, both in terms of quantity and purpose. Buttons can be positioned directly below the message (InlineKeyboardButton) or docked below the text box for entering a message (KeyboardButton). 

make your own chatbot

Receiving the information

In addition to text messages, bots can communicate using:

  • Images;

  • Audio files;

  • Video files;

  • Lists;

  • Carousels;

  • Buttons;

  • Receipts (for example, for a purchase);

  • Templates (often used when booking something, for example, air tickets);

  • Navigation menu.

Users can reply with text, emoticons, GIFs, images, audio, video, and pull chatbots into group chats.

What if the chatbot doesn't know how to answer the question?

Developers build a conversation map and, depending on the question, the person is given an automatic answer on websites, messengers, or applications. A chatbot is most convenient to use where processes are properly structured. For example, to buy a train ticket. Since the possible routes, schedule, availability of seats are known, the dialogue map is easy to build, and system errors are reduced to zero.

When the webserver runs out of answers to the customer's questions, the webserver can connect the operator to the chat. Each question of the client and the answer of the operator, the web server can save in the database for optimizing the bot.

The chatbot can answer questions based on the user's correspondence history or respond with prepared response templates.

Each new user will have an empty correspondence at startup, at which time the chatbot can send only one greeting message. When the user sends their first message, they automatically subscribe to the bot. Each message can contain an arbitrary keyboard with options for actions. Since each user has a unique ID, the web server can rely on the saved correspondence history of a particular user and, based on the history, send different responses to the client, or help the operator to join the conversation without the user noticing.

How to create a smart chatbot?

All messages entered by the user are transmitted and processed on the webserver. The web server can return an arbitrary keyboard with buttons, each button can perform some action, for example: go to the site, create a new message, write the user's mobile phone, write the user's location.

The simplest chatbot should have its own knowledge base, which is a set of possible user questions and their corresponding answers. The chatbot can select responses in several ways:

  • By keywords;

  • By phrase coincidence;

  • By a coincidence of context.

A kind of mini-problem for such simple bots is the identification of word forms and synonyms.

Dialogflow

Writing AI for a bot is not an easy task, so you can use a solution from Google.
The following functions are available:

  • Creating answers to standard questions;

  • Creation of topics of conversation for non-standard or specific requests.

  • During the conversation, a suitable dialogue will be selected;

  • Training (adjusting bot responses based on the chat history);

  • Analytics (number of requests, the course of the dialogue, which topics are most often triggered).

Supported languages: English, Russian

Integration: Viber (deprecated, they suggest using the library for Nodejs), Telegram, Skype (deprecated), Twilio (deprecated), Facebook, Slack.

Aimylogic 

Excellent service for creating all the familiar "text" bots and unusual bots for calling (for a paid plan). Fun but difficult to learn features like intents and entities. Suitable for creating AI and taking over the world.

It lacks the usual functions: a basket, creating an inline keyboard, sending a file, but you can create a bot that will guess what they write about.

Supported languages: English, Russian

Integration: WhatsApp, Facebook, VK.

Final thoughts

WhatsApp, Viber, Telegram, WeChat, Line, Facebook Messenger, and others. These messengers are convenient and they have become a familiar means of communication. Every day they fill our daily life more and more. We communicate with friends and relatives, colleagues in chats. And it became commonplace.

Thanks to the digitalization of life, all our affairs, events, entertainment apps are in our favorite smartphone and messengers. And why?

Because 60% of users who want to place an order for a product, product, or service prefer to write a message rather than call. Of these, 30% use instant messaging. It is not surprising that instant messengers have confidently begun to overtake social networks.

First, we stopped calling and switched to text communication, now we stop writing manually, and with one click we select from the suggested answers by the chatbot.

The main thing is to comply with the restrictions and try to create a chatbot as smart as possible. If you still have questions on chatbot development, our team will gladly take this headache away from you.
 

Interested in this expertise?

Get in touch with us and let's discuss your case. We will gladly share our knowledge and experience with you and find the most suitable option for you.

 
Diana
Tarazevich
Head of sales department

See also