9 个版本

0.6.18 2023 年 10 月 9 日
0.6.17 2023 年 8 月 23 日
0.6.16 2023 年 7 月 14 日
0.6.15 2023 年 3 月 22 日
0.6.8 2022 年 2 月 9 日

#1348 in 网页编程

每月 32 下载量

MIT/Apache

290KB
3.5K SLoC

rutel

Telegram Bot APIRust 实现

Telegram Bot API 6.9


lib.rs:

Telegram 机器人 APIRust 编程语言 实现。它处理所有困难的事情,让您只需关注业务逻辑。

要了解高级概述,请参阅 我们的 GitHub 仓库

[examples/throw_dice.rs]

use teloxide::prelude::*;

pretty_env_logger::init();
log::info!("Starting throw dice bot...");

let bot = Bot::from_env();

teloxide::repl(bot, |bot: Bot, msg: Message| async move {
    bot.send_dice(msg.chat.id).await?;
    Ok(())
})
.await;

依赖关系

~8–18MB
~247K SLoC