Walle-core

OneBot11 OneBot12 license

Walle-core 是一个 Rust OneBot Lib ( 不同于 libonebot 他同样可以应用于 OneBot 应用端 )

Walle 的名字来源于机械总动员的 WALL-E ( A Rusty Bot )

功能

features

How to use

仅展示最小实例

Implementation

```rust use walle_core::{ImplConfig, impls::OneBot, DefaultHandler};

[tokio::main]

async fn main() { tracingsubscriber::fmt().init(); // 初始化 tracing let config = ImplConfig::default(); let ob = OneBot::new( "Your impl name".toowned(), "Your impl platform".toowned(), "Your bot self id".toowned(), config, DefaultHandler::arc(), // ActionHandler ).arc(); ob.run().await ... // run is not blocking do your own things } ```

Application

```rust use walle_core::{AppConfig, app::OneBot, DefaultHandler};

[tokio::main]

async fn main() { tracingsubscriber::fmt().init(); // 初始化 tracing let config = AppConfig::default(); let ob = OneBot::new( config, DefaultHandler::arc(), // EventHandler ).arc(); ob.run().await ... // run is not blocking do your own things // or use runblock().await } ```