Skip to content

Basic telegram bot for getting basic community information

Notifications You must be signed in to change notification settings

ybgirgin3/telegram-git-bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Telegram Git Bot

Basic telegram bot for getting any community informations from telegram without opening heavy browsers and log in github account

How to make it work

Before running this python telegram bot you have to install required telegram bot for python;

pip3 install python-telegram-bot

then follow telegram bot creation tutorial from https://core.telegram.org/bots because you will need bot key to make this bot work. You will get the key from telegram's BotFather after giving your bot name and other needed specificaton. Key is important because everybody that who has this key has access to change your bot completely. You need to add key to here:

# telegram-github-bot.py line: 20
updater = Updater("your telegram bot key")	# ADD YOUR KEY HERE

Github Entegration

Github entegration is bit of complex (at least for me). You need to get your personal account's or community account's api from https://developer.github.com/v3/

For example;

Api needs to be like "https://api.github.com/orgs/(your_community/organization_name)" for organization/community account

You can run your api in the browser to control if it's running truely or not.

API NEEDS TO BE A JSON FILE

After getting api you need to paste the api url to;

# git_process.py line: 14
f = requests.get("your community github api").text 	# ADD YOUR API HERE

and it's done !!.

Now you can test your telegram bot with running 'telegram-github-bot.py' file. For testing it you can give your telegram bot /hello command and for getting informations you can give your bot /commands command and also you can give your bot /dog command to see silly, cute, awesome dog pics :)

This file wrote in python3 and it's highly recommended for avoid errors

About

Basic telegram bot for getting basic community information

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages