Python Framework for Telegram's Bot API
Install it this way:
pip install requests
Bot Sample
import nestar
def handle(bot, update):
print(update)
bot = nestar.Nestar("YOUR:TOKEN")
bot.loop(handle)
Plugin Sample
class NestarPlugin:
def handle(self, bot, update):
bot.sendMessage(chat_id=update["message"]["from"]["id"], text="Hi! Welcome to Nestar, {}".format(update["message"]["from"]["first_name"]))
You won't need an handler if there is at least one plugin in the plugins folder.