Build own Telegram Bot with Node.js

Love Calculator on Telegraf

Gapur Kassym
The Startup

--

Photo by Alex Knight on Unsplash

Since Telegram Bot has appeared, I always interested in how they work. So I decided to build simple Telegram Bot with Node.js and Telegraf. Telegraf is a modern bot framework for Node.js. They have friendly documentation and examples.

In this tutorial I will develop a love calculator bot. I used free love calculator api. You should enter your name and name of your partner/lover/crush to find Love compatibility & chances of successful love relationship.

Let’s start and do it together.

Create own Bot with BotFather

BotFather

First, We should create own bot with BotFather. BotFather is the one bot to rule them all. We will use it to create new bot accounts and manage your existing bots.

If you open a chat with a BotFather, click on the “Start” button.

First screen

After that, the bot gives us all the commands.

--

--

Gapur Kassym
The Startup

Senior Software Engineer at Twilio, Technical Writer #JavaScript #React #React-Native #Nodejs. Follow me on twitter https://twitter.com/GKassym