telebot
-------
A Telegram bot library, with simple route decorators.
Currently a work in progress, doesn't do much now, but will register and send messages.
Example Setup
^^^^^^^^^^^^^
::
from telebot import TeleBot
app = TeleBot(__name__)
@app.route('/command ?(.*)')
def example_command(message, cmd):
chat_dest = message['chat']['id']
msg = "Command Recieved: {}".format(cmd)
app.send_message(chat_dest, msg)
@app.route('(?!/).+')
def parrot(message):
chat_dest = message['chat']['id']
user_msg = message['text']
msg = "Parrot Says: {}".format(user_msg)
app.send_message(chat_dest, msg)
if __name__ == '__main__':
app.config['api_key'] = 'xxxxxxxx:enterYourBotKeyHereToTest'
app.poll(debug=True)
Raw data
{
"_id": null,
"home_page": "https://github.com/KyleJamesWalker/telebot",
"name": "telebot",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "",
"author": "Kyle James Walker",
"author_email": "KyleJamesWalker@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/11/73/fa8dafd14139a36591314fe219c58cd39db76b8ac8254edf3b49e4011d5c/telebot-0.0.4.tar.gz",
"platform": "",
"description": "telebot\n-------\n\nA Telegram bot library, with simple route decorators.\n\nCurrently a work in progress, doesn't do much now, but will register and send messages.\n\nExample Setup\n^^^^^^^^^^^^^\n::\n\n from telebot import TeleBot\n\n app = TeleBot(__name__)\n\n\n @app.route('/command ?(.*)')\n def example_command(message, cmd):\n chat_dest = message['chat']['id']\n msg = \"Command Recieved: {}\".format(cmd)\n\n app.send_message(chat_dest, msg)\n\n\n @app.route('(?!/).+')\n def parrot(message):\n chat_dest = message['chat']['id']\n user_msg = message['text']\n\n msg = \"Parrot Says: {}\".format(user_msg)\n app.send_message(chat_dest, msg)\n\n\n if __name__ == '__main__':\n app.config['api_key'] = 'xxxxxxxx:enterYourBotKeyHereToTest'\n app.poll(debug=True)\n\n\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "A Telegram bot library, with simple route decorators.",
"version": "0.0.4",
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"md5": "ccf46631757bf214571ba153b16c382a",
"sha256": "1d692ee3c2f07c5caacb1a82f0b59e40cef84f58be84435be9c8ce667dee94a6"
},
"downloads": -1,
"filename": "telebot-0.0.4-py3-none-any.whl",
"has_sig": false,
"md5_digest": "ccf46631757bf214571ba153b16c382a",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 4599,
"upload_time": "2020-11-18T17:40:38",
"upload_time_iso_8601": "2020-11-18T17:40:38.692273Z",
"url": "https://files.pythonhosted.org/packages/05/47/4ca2e24ff82d2f5f20e02a90ade45e97bf596c0a68733c79f29327c92f41/telebot-0.0.4-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"md5": "4014e69b0a646b2d205d0efa7d8ce50e",
"sha256": "717f08f0cbb2b3bbba73e8b36cca466345b751d44e938235eaa24139073f3265"
},
"downloads": -1,
"filename": "telebot-0.0.4.tar.gz",
"has_sig": false,
"md5_digest": "4014e69b0a646b2d205d0efa7d8ce50e",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 3914,
"upload_time": "2020-11-18T17:40:40",
"upload_time_iso_8601": "2020-11-18T17:40:40.215669Z",
"url": "https://files.pythonhosted.org/packages/11/73/fa8dafd14139a36591314fe219c58cd39db76b8ac8254edf3b49e4011d5c/telebot-0.0.4.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2020-11-18 17:40:40",
"github": true,
"gitlab": false,
"bitbucket": false,
"github_user": "KyleJamesWalker",
"github_project": "telebot",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"tox": true,
"lcname": "telebot"
}