From 2c631b297396207ebc54c406a13a88af417f51a8 Mon Sep 17 00:00:00 2001 From: Andrew Developer Date: Thu, 23 Mar 2017 15:34:33 +0300 Subject: [PATCH] Added webhook example with Tornado --- .../webhook_tornado_echo_bot.py | 94 +++++++++++++++++++ 1 file changed, 94 insertions(+) create mode 100644 examples/webhook_examples/webhook_tornado_echo_bot.py diff --git a/examples/webhook_examples/webhook_tornado_echo_bot.py b/examples/webhook_examples/webhook_tornado_echo_bot.py new file mode 100644 index 0000000..538b7b9 --- /dev/null +++ b/examples/webhook_examples/webhook_tornado_echo_bot.py @@ -0,0 +1,94 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- + +# This example shows webhook echo bot with Tornado web framework +# Documenation to Tornado: http://tornadoweb.org + +import telebot +import tornado.web +import tornado.ioloop +import tornado.httpserver +import tornado.options +import signal + +API_TOKEN = '' +WEBHOOK_CERT = "./cert.pem" +WEBHOOK_PKEY = "./pkey.pem" +WEBHOOK_HOST = "" +WEBHOOK_SECRET = "