Simple IM Framework based on satori-python
Project description
Entari
lo su etheclim, ti zo entaem rish.
一个基于 Satori
协议的简易 IM framework
示例
复读:
from arclet.entari import ContextSession, Entari, WS
app = Entari(WS(host="127.0.0.1", port=5140, path="satori"))
@app.on_message()
async def repeat(session: ContextSession):
await session.send(session.content)
app.run()
指令 add {a} {b}
:
from arclet.entari import ContextSession, Entari, EntariCommands, WS
command = EntariCommands()
@command.on("add {a} {b}")
async def add(a: int, b: int, session: ContextSession):
await session.send(f"{a + b = }")
app = Entari(WS(port=5500, token="XXX"))
app.run()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
arclet_entari-0.4.1.tar.gz
(15.5 kB
view hashes)
Built Distribution
Close
Hashes for arclet_entari-0.4.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 452bbaa4ad3261aac1e023eb0170dcbc8fc16879d464b3afda061a1c59a61310 |
|
MD5 | 3f8bbd6c9674ab52c1bf4b652482c0ad |
|
BLAKE2b-256 | 8135483e8a0f9659874abfca949ebed7f6af5ea5cde7d1d9a710b1e8784d705b |