Please Provide me with the full discord bot(Simple like Mee6) Code in Python
Code one yourself. But here is the basic Bot code. He can only say pong! when you type !ping:
import discord import os
client = discord.Client()
client = commands.Bot(command_prefix = '!') #prefix
@client.event async def on_ready(): print("bot online") #will print "bot online" in the console when the bot is online
@client.command() async def ping(ctx): await ctx.send("pong!")
client.run(os.getenv("TOKEN"))
Not code: Insert your bot link into the environmental variable with the "key" TOKEN
Code one yourself. But here is the basic Bot code. He can only say pong! when you type !ping:
import discord
import os
client = discord.Client()
client = commands.Bot(command_prefix = '!') #prefix
@client.event
async def on_ready():
print("bot online") #will print "bot online" in the console when the bot is online
@client.command()
async def ping(ctx):
await ctx.send("pong!")
client.run(os.getenv("TOKEN"))
Not code:
Insert your bot link into the environmental variable with the "key" TOKEN