mirror of
https://codeberg.org/JasterV/YoutuBot.git
synced 2026-04-26 18:40:02 +00:00
Add files via upload
This commit is contained in:
parent
d33bdd6d0d
commit
d428cdf140
3 changed files with 17 additions and 3 deletions
13
app.py
13
app.py
|
|
@ -2,10 +2,12 @@ import telebot
|
|||
import time
|
||||
import pafy
|
||||
import os
|
||||
from flask import Flask
|
||||
|
||||
bot_token = os.getenv('BOT_TOKEN')
|
||||
|
||||
bot_token = '837420348:AAEY2WT04zBjpCHYvOzCdy4FHhZf8jX6udE'
|
||||
bot = telebot.TeleBot(token=bot_token)
|
||||
|
||||
server = Flask(__name__)
|
||||
|
||||
@bot.message_handler(commands=['start'])
|
||||
def send_welcome(message):
|
||||
|
|
@ -35,6 +37,13 @@ def download_song(message):
|
|||
return filename
|
||||
|
||||
|
||||
@server.route("/")
|
||||
def webhook():
|
||||
bot.remove_webhook()
|
||||
bot.set_webhook(url='https://cryptic-crag-46329.herokuapp.com/' + bot_token)
|
||||
return "!", 200
|
||||
|
||||
|
||||
while True:
|
||||
try:
|
||||
bot.polling()
|
||||
|
|
|
|||
|
|
@ -42,6 +42,7 @@ prettytable==0.7.2
|
|||
proglog==0.1.9
|
||||
protobuf==3.6.1
|
||||
pycairo==1.16.2
|
||||
pycrypto==2.6.1
|
||||
pycups==1.9.73
|
||||
pydbus==0.6.0
|
||||
PyGObject==3.32.0
|
||||
|
|
@ -53,6 +54,8 @@ python-apt==1.8.4
|
|||
python-telegram-bot==12.1.1
|
||||
python-xlib==0.23
|
||||
pytz==2018.9
|
||||
pyxdg==0.25
|
||||
PyYAML==3.13
|
||||
Repoman==1.0.2
|
||||
requests==2.21.0
|
||||
requests-unixsocket==0.1.5
|
||||
|
|
@ -70,6 +73,7 @@ tqdm==4.36.1
|
|||
ubuntu-advantage-tools==19.2
|
||||
ubuntu-drivers-common==0.0.0
|
||||
ufw==0.36
|
||||
urllib3==1.24.1
|
||||
Werkzeug==0.16.0
|
||||
xkit==0.0.0
|
||||
youtube-dl==2019.9.28
|
||||
|
|
|
|||
1
runtime.txt
Normal file
1
runtime.txt
Normal file
|
|
@ -0,0 +1 @@
|
|||
python-3.7.3
|
||||
Loading…
Add table
Add a link
Reference in a new issue