mirror of
https://github.com/Llloooggg/Jarvis.git
synced 2026-03-06 03:56:23 +03:00
24 lines
669 B
Python
24 lines
669 B
Python
import telebot
|
|
|
|
botToken = ""
|
|
bot = telebot.TeleBot(botToken)
|
|
|
|
|
|
# telebot.apihelper.proxy = {}
|
|
# прокси, если нужен, в
|
|
# формате {'https': 'login:password@address:port'}
|
|
|
|
|
|
@bot.message_handler(commands=["start"]) # Реакция на команду start
|
|
def start_message(message):
|
|
bot.send_message(
|
|
message.chat.id,
|
|
"Добро пожаловать в Jarvis!\n"
|
|
"Это помощник, сценарии поведения которого настраиваются через ",
|
|
"web-приложение на Flask\n",
|
|
)
|
|
|
|
|
|
def send_message(user_id, text):
|
|
bot.send_message(user_id, text=text)
|