#webhook #discord #discord-webhook

DiscordMessenger

A library that allows you to easily send discord webhooks

1 stable release

1.0.0 Jun 1, 2021

#95 in #webhook

Download history 1/week @ 2024-02-14 8/week @ 2024-02-21 5/week @ 2024-02-28 1/week @ 2024-03-27

54 downloads per month

Apache-2.0

11KB
348 lines

DiscordMessenger-Rust

A library that allows you to easily send discord webhooks

Usage

Add to the Cargo.toml on dependencies DiscordMessenger = "1.0.0"

Example

use DiscordMessenger::{DiscordMessage, EmbedBuilder};

fn main() {
    DiscordMessage::new()
        .set_content("Hello World from the best lib".to_string())
        .add_embed(EmbedBuilder::new()
            .set_title("Feli".to_string())
            .set_description("An embed using the discord messenger library".to_string())
            .build())
        .set_username("Discord Messenger".to_string())
        .send("https://discord.com/api/webhooks/xxxx/xxxx".to_string());
}

Dependencies

~15–26MB
~444K SLoC