mirror of
https://github.com/maubot/maubot.git
synced 2024-10-01 01:06:10 -04:00
11 lines
329 B
Python
11 lines
329 B
Python
from mautrix.types import EventType
|
|
from maubot import Plugin, MessageEvent
|
|
from maubot.handlers import event
|
|
|
|
|
|
class HelloWorldBot(Plugin):
|
|
@event.on(EventType.ROOM_MESSAGE)
|
|
async def handler(self, event: MessageEvent) -> None:
|
|
if event.sender != self.client.mxid:
|
|
await event.reply("Hello, World!")
|