mirror of
https://github.com/stoatchat/python-client-sdk.git
synced 2026-07-21 10:05:22 -04:00
17 lines
399 B
Python
Executable File
17 lines
399 B
Python
Executable File
import asyncio
|
|
import aiohttp
|
|
import revolt
|
|
|
|
|
|
class Client(revolt.Client):
|
|
async def on_message(self, message: revolt.Message):
|
|
if message.content == "hello":
|
|
await message.channel.send("hi how are you")
|
|
|
|
async def main():
|
|
async with aiohttp.ClientSession() as session:
|
|
client = Client(session, "BOT TOKEN HERE")
|
|
await client.start()
|
|
|
|
asyncio.run(main())
|