Advertisement
Techniker357

Untitled

Dec 8th, 2019
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.41 KB | None | 0 0
  1. # bot.py
  2. import os
  3. import random
  4.  
  5. import discord
  6. from discord.ext import commands
  7. from dotenv import load_dotenv
  8.  
  9. load_dotenv()
  10. token = os.getenv('DISCORD_TOKEN')
  11.  
  12. bot = commands.Bot(command_prefix='!')
  13.  
  14. @bot.command(pass_context=True)
  15. async def xsend(ctx, *, message):
  16.     await Bot.delete_message(ctx.message)
  17.     await Bot.send_message(discord.Object(id='408104999038746635'), message)
  18.  
  19. bot.run(token)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement