FanaticExplorer

python_bot

Jan 3rd, 2022 (edited)
207
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.35 KB | None | 0 0
  1. import discord
  2. from discord.ext import commands
  3.  
  4. bot = commands.Bot(command_prefix='>')
  5.  
  6. @bot.event
  7. async def on_ready():
  8.     print('Logged in as')
  9.     print(bot.user.name)
  10.     print(bot.user.id)
  11.     print('------')
  12.  
  13. async def on_message(self, message):
  14.         print(f'Message from {0.author} {0.content}'.format(message))
  15.  
  16.  
  17. bot.run(bot_token)
Add Comment
Please, Sign In to add comment