bot-python-sdk
bot-python-sdk copied to clipboard
اجرا نکردن get_message
. ارور زیر رو میده وقتی
get_message
رو اجرا میکنم.
Invalid URL '<Response [200]>': No schema supplied. Perhaps you meant http://<Response [200]>? retry to connect after 10 seconds...
کد رو هم تغییر ندادم. به راحتی پیام ارسال میکنم ولی دریافت رو مشکل دارم!
from sys import path path.append('..') from client import Client
bot_token = 'atyJDqAzb0p-*******************J-W'
bot = Client(bot_token)
try: messages = bot.get_messages() for message in messages: print("New message from {} \nType: {}\nBody: {}" .format(message['from'], message['type'], message['body']))
except Exception as e: print(e.args[0])