libawr 0.1.0

基于 ricq 的 QQ 机器人框架,提供一致、易用、简洁的 API。
Documentation

基于 ricq 的 QQ 机器人框架,提供一致、易用、简洁的 API。

更多信息,请参考 loginClient

Examples

Rust

use libawr::{login, msg, Protocol};
use anyhow::Result;

#[tokio::main]
async fn main() -> Result<()> {
let (client, alive) = login!(12345678, password="******", protocol=Protocol::IPad).await?;
client.friend(23456789).send(msg!("Hello, world!")).await?;
alive.auto_reconnect().await?;
unreachable!()
}

Python

import asyncio
import awr

async def main():
client, alive = await awr.login(12345678, password="******", protocol=awr.Protocol.IPad)
await client.friend(23456789).send("Hello, world!")
await alive.auto_reconnect()

asyncio.run(main())