Telegram Bot

in #telegrambot6 years ago (edited)

Hi people, today we are going to create a telegram Bot and obtain his Token and Chat-id.

Open telegram

Search Bottom for ( BotFather )

or

https://telegram.me/botfather

START Dialog

/newbot

Screenshot from 2018-05-29 02-07-02.png

 Write the Name for your Bot

Screenshot from 2018-05-29 02-14-57.png
Someprivate:token123456

Screenshot from 2018-05-29 02-15-31.png

Screenshot from 2018-05-29 02-15-42.png

 Click on the Bot-name created and add some description. 

for more commands and setup

/help

Screenshot from 2018-05-29 02-27-44.png

Here is done you have created one Telegram bot. take the token file and bot name and saved for later.

It does not matter if you close the chat with Botfather, the bot is already created and you have already saved your keys.

SEARCH YOUR BOT AND OPEN CHAT WITH THE BOT

Screenshot from 2018-05-29 02-36-45.png
Important said hi.

Screenshot from 2018-05-29 02-43-44.png

Now leave telegram open and open Ubuntu terminal

sudo apt install python-pip

sudo pip install python-telegram-handler

After install:
You are using pip version 8.1.1, however version 10.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
DONT DO . ANY UPGRADE.

sudo python -m telegram_handler <your token here>

Screenshot from 2018-05-29 02-51-35.png

CONGRATULATIONS

Now you have One TelegramBot with Token and CHAT-ID

For more info about telegram bot

https://core.telegram.org/bots#6-botfather

Github repo

https://github.com/sashgorokhov/python-telegram-handler

Have nice day and enjoy your bot.

http://melea.es/contac/

https://twitter.com/cryptoMelea

https://www.instagram.com/cryptomelea/

https://www.reddit.com/user/iammelea

https://keybase.io/melea

https://github.com/iammelea

https://steemit.com/@melea

https://t.me/melea_trader

http://melea.es/