Knowledge is the gold of nowadays

Enjoy and share valuable information to make better solutions

Create chatbot for Telegram (Part 1)

Today the number of users of messaging apps like WhatsApp, Slack, Skype and their analogs is skyrocketing, With the spread of messengers, virtual chatterbots that imitate human conversations for solving various tasks are becoming increasingly in demand. In this series of articles, we will describe in details how easily setup and launch chatbot for one of the most dynamically growing messenger, Telegram.

What is chatbot and what is it for?

It is an assistant that communicates with us through text messages, a virtual companion that integrates into websites, applications or instant messengers and helps entrepreneurs to get closer to customers. Such a bot is an automated system of communication with users.

Why does a business need chatbots? There are reasons for that like getting rid of routine tasks and simultaneous processing of multiple requests from users. Besides, a tremendous speed of processing users’ requests with chatbots helps in gaining customers’ loyalty.

So welcome friend, this tutorial is first in series of articles to show you how to create your first bot, connect it to Onlizer and program it to teach him "Intelligent Things". What "things" exactly? Will show you later, do not rush, keep everything in order :) What can be said now - gradually, step by step, your bot will become smarter and more progressive, and you will see what incredible scenarios can be done with chatbots.

So do not waste time and let's do it!

Create a new bot with BotFather

The process of creating a new bot in the telegram messenger is performed with the help of "Father of all Bots" @BotFather. This bot is the basic tool for creation of new bots in Telegram.
BotFather is the only bot that guides everyone. Use it to create new accounts and manage existing bots.

  1. To begin with, we need Telegram Messenger, so make sure it is installed on your device, if not here is link.
  2. Now launch Telegram, open the main view and search for "@BotFather
  3. We choose a man in a tuxedo with "verified" badge and, if you like, read the information about him. Then we start communication with him - press the "Start" button.
  4. After the start, a list of commands appears for us to create new accounts and manage the existing bots owned by BotFather. So, from this list, select the /newbot command, which is designed to create a new bot in Telegram.
  5. Next, you need to enter a name for your bot (the name can later be changed with the /setname command) and a unique username (nickname), which should end with the word "bot" or "Bot."
    WARNING! Bot's username must be unique and can not be changed later!
  6. Okay, well, if you have done everything right and Telegram has accepted your bot's unique username (nickname), then you should see a message that contains the unique token of your bot. Copy and save it (don't try to remember this code,  it's hard ;) ), we will need it in the next steps.

Congratulations, this is all we need to go further! Read next article Create chatbot for Telegram (Part 2)
But if you are interested, below we will set the additional parameters of our bot for better appearance in Telegram :)

Set bot's additional parameters

  1. Now let's describe what our bot is capable of or why we created it. Select the /setdescription command and in the popup menu select our bot from the list of bots we created. You can find a bot by a unique nickname we provide earlier.
  2. Next, enter the description of the bot (use some clear and interesting text to catch attention). 
  3. To be continued...