Rust telegram bot library for many runtimes

Related tags

Miscellaneous telbot
Overview

Telbot

Active Development

Telbot provides telegram bot types and api wrappers.

Specifically, telbot now supports:

  • telbot-types: basic telegram types / requests / responses
  • telbot-cf-worker: api wrapper for cloudflare workers
    • get-me request example
    • echo bot example
You might also like...
Uradhura is a telegram bot that fetches information and media from reddit
Uradhura is a telegram bot that fetches information and media from reddit

Pathetic little Telegram bot that fetches information from Reddit posts(with gif, image(post with single image) and video)

A Telegram bot to watch animes

AmimeWatch A Telegram bot to watch animes. Re-written version of AmimeWatch in Rust. Preparing Configuration Create a file named config.toml and fill

An out-of-box ChatGPT bot for Telegram.
An out-of-box ChatGPT bot for Telegram.

TeleGPT API Docs | Releases | Twitter An out-of-box ChatGPT bot for Telegram. TeleGPT is a Telegram bot based on teloxide framework and async_openai.

An out-of-box ChatGPT bot for Telegram.
An out-of-box ChatGPT bot for Telegram.

TeleGPT API Docs | Releases | Twitter An out-of-box ChatGPT bot for Telegram. TeleGPT is a Telegram bot based on teloxide framework and async_openai.

A Telegram ChatGPT bot
A Telegram ChatGPT bot

A customizable Telegram bot with a ChatGPT (or GPT4, bring your own API key) backend. You can configure the bot’s context and prompt in template settings.

A simple telegram bot to get the tunnel info from ngrok.
A simple telegram bot to get the tunnel info from ngrok.

Telegram Ngrok Bot A simple bot to fetch the running tunnels from ngrok api. Prerequisits Ngrok agent should be running. Configuration Ngrok config ve

Matrix bot inspired by Shirt Bot.

matrix-openai-bot Matrix bot inspired by Shirt Bot. Usage Run the bot after building it or grabbing the latest release $ matrix-openai-bot Edit the ge

Rewrite of the Discord Bot used for Managing the Infinity Bot List Servers.
Rewrite of the Discord Bot used for Managing the Infinity Bot List Servers.

Arcadia Rewrite of the Discord Bot used for Managing the Infinity Bot List Servers. Contributing Always run fmt.sh before making a Pull Request! MacOS

Annoyed that Rust has many string types? Well it doesn't have to

generic-str The one true string type in Rust! This project intends to be a proof-of-concept for an idea I had a few months back. There is lots of unsa

Comments
  • Capiton are json encoded even when not send as json

    Capiton are json encoded even when not send as json

    Hello,

    When I try to send a file with a caption it is surrounded by " and if it contain the character " it is send as \".

    Here a minimal example:

    use telbot_ureq::types::message::SendDocument;
    use telbot_ureq::types::chat::ChatId;
    use telbot_ureq::types::file::InputFile;
    use telbot_ureq::Api;
    
    fn main() {
    	let data: Vec<u8> = "exemple".to_string().into_bytes();
    	let caption = "exemple \" exemple";
    
    	let api = Api::new("...".to_string());
    	let chat_id: ChatId = 123456789i64.into();
    
    	let file = InputFile {
    		name: "test.txt".to_string(),
    		data: data,
    		mime: "text/plain".to_string(),
    	};
    
    	api
    		.send_file(
    			&SendDocument::new(chat_id, file)
    				.with_caption(caption)
    		)
    		.expect("Error while sending document to Telegram");
    }
    

    And here what I get in Telegram:

    image

    From what I can see the problem is that the send_file method use serde_json::to_value but the body is not send as json (but as multipart) so the text is json escaped but Telegram do not decode it.

    PS: I'm using the main version from git telbot-ureq = { git = "https://github.com/kiwiyou/telbot" }

    bug 
    opened by neodc 3
Owner
kiwiyou
Student Rust Programmer - longing for knowledge
kiwiyou
Telegram bot to fetch images from Terceira Ponte and Rodosol into your Telegram chat.

rodosol-telegram-bot Add this bot to your contacts list This bot is a quick scraper that gets the pictures from the rodosol "De olho na via" feature a

Armando Magalhães 1 Jan 9, 2022
A Simple, But amazing telegram bot, Made using the Rust language!

Telegram bot in Rust A fun Telegram bot made using Rust language.

Deep Alchemy 2 Dec 21, 2021
This is a Telegram bot I'm working on in my free time to learn Rust.

Maldness Bot This is a Telegram bot I'm working on in my free time to learn Rust. Building docker build -t . should be enough.

Sergey Kislyakov 10 May 13, 2022
Telegram bot for searching in Arch User Repository ( AUR ); Implemented using rust.

AurSearchBot A Telegram Inline Search Bot Written in Rust Introduction Telegram Bot that can search AUR ( Arch User Repository ) in inline mode. This

AlenPaulVarghese 3 Feb 15, 2022
Autogenerated wrapper for the Telegram Bot API written in Rust.

An Elegant Rust Client for Telegram Bot API crates.io • docs.rs Table of contents Introduction Key Features Installation Getting Started Documentation

FerrisGram 22 Oct 29, 2022
A simple Telegram bot that eats anonymous channel messages, written in Rust.

tgbot-nochanmsg By Asuna Right Control When creating your bot from botfather, it's not bad to disable privacy mode, because it needs to access the mes

h3a.moe 2 Aug 5, 2022
A Telegram bot written in Rust.

Knight-Bot Table of Contents About Support chat Installation Setting up your environment Build manually Commands Commands on TODO list Find this bot A

cyberknight777 25 Apr 27, 2023
This is a simple Telegram bot with interface to Firefly III to process and store simple transactions.

Firefly Telegram Bot Fireflies are free, so beautiful. (Les lucioles sont libres, donc belles.) ― Charles de Leusse, Les Contes de la nuit This is a s

null 13 Dec 14, 2022
Telegram Bot Template with Cloudflare Workers

cf-workers-telegram-bot-template Usage This template starts you off with a src/lib.rs file, acting as an entrypoint for requests hitting your Worker.

Lee Taehoon 2 Sep 23, 2021
Telegram bot that zhuzh Twitter content

@twt_2_tg_bot Telegram bot that zhuzh shared Twitter content Text converter Some tweets may contain line breaks or even dialogs. Such tweets are barel

Vladimir 6 Nov 6, 2022