dyncord 0.13.6

A high-level, ergonomic, batteries-included Discord bot library for Rust. WIP.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
use std::env;

use dyncord::events::{EventContext, On};
use dyncord::{Bot, Intents};
use twilight_gateway::Event;

#[tokio::main]
async fn main() {
    let bot = Bot::new(())
        .intents(Intents::MESSAGE_CONTENT)
        .intents(Intents::GUILD_MESSAGES)
        .on_event(On::event(on_event));

    bot.run(env::var("TOKEN").unwrap()).await.unwrap();
}

async fn on_event(_ctx: EventContext<(), Event>) {}