Telegex - Telegram bot library, full support for the latest API versions

Hi, I’ve just released the first officially available version of Telegex, 0.1.0. It can be used to build Telegram bots, and supports the latest bot API version 4.9 (and will keep the latest version supported).

There are two existing libraries, Nadia and ExGram, which are also very good, but I’m trying to make it easier to get to the root of the problem with the to replace them, and it worked.

Telegex not only supports all methods of bot API, but also has perfect typespecs. You can even see the name of each optional field.

For the method of including attachments, it can automatically determine whether the attachment is a remote file ID or a local file. And automatically correct to attach-syntax (when a method contains multiple attachments, it is necessary, but you only need to simply provide the file path).

And, it is very safe to pattern match the return value of Telegex, because it returns the model struct instead of map.

I love Elixir, I love Telegram :innocent:

11 Likes

Telegram is severely under-appreciated!

Thanks for the library, I could see myself using it.

2 Likes

It looks great! Thanks for the library!

Great, but I have one request
Please, let the token be set at runtime
I have an application that have to send telegram messages to more then one client
Look how Nadia is doing this

config :nadia,
  recv_timeout: 10,
  token: {:system, "TELEGRAM_TOKEN", ""}

Truly great, I’ve put a star on the repo. I’m using it myself right now on a project, and perhaps I’ll be posting about it soon enought. Again thanks for your work. :wink: