def greet_user(message): random_number = random.randint(0, len(emotions.salutations) - 1) greeting = emotions.salutations[random_number] uid = get_user_credentials(message)['uid'] first_name = get_user_credentials(message)['first_name'] last_name = get_user_credentials(message)['last_name'] text = f"{greeting} {first_name} {last_name}." bot.send_message(uid, text=text)
def send_animated_message(message, message_text, category): attach_video(message, category) bot.send_message(message.from_user.id, message_text)
def send_manual_to_user(message): uid = get_user_credentials(message)['uid'] bot.send_message(uid, text=manual)
def log(*data): if should_log: bot.send_message(dev, ', '.join([str(x) for x in data]), parse_mode='html')