Giter Site home page Giter Site logo

elixir-tdlib's Introduction

Elixir TDLib

This elixir library binds telegram's TDLib, allowing you to interact with Telegram as a full-fledged client (not as a bot!). It ships :

Most of the interactions with this project are done via the TDLib module. Any structure used to interact with TDLib is defined under either TDLib.Object or TDLib.Method. You can create as many session as you want, but note that each of them launch a new instance of tdlib-json-cli via a port.

Installation

Add the following to your mix.exs :

def deps do
  [{:tdlib, "~> 0.0.2"}]
end

Note that compiling this project will compile Telegram's TDLib (C++) itself, it's going to take a while and depends on the following :

  • C++14 compatible compiler (clang 3.4+, GCC 4.9+, MSVC 19.0+ (Visual Studio 2015+), Intel C++ Compiler 17+)
  • OpenSSL
  • zlib
  • gperf
  • CMake (3.0.2+)

Configuration

This library does not need configuration, however, the following options are available :

# Disable automatic handling of authentification and directly forward the
# incoming messages to the client
config :telegram_tdlib, disable_handling: false

# Override default path of the telegram-json-cli binary
config :telegram_tdlib, backend_binary: "/path/to/my/binary"

Usage / Example

A simple example can be found at git.sr.ht/~fnux/elixir-tdlib-demo. Please refer to the TDLib module for proper documentation.

elixir-tdlib's People

Contributors

adodulad avatar fnux avatar mrgrinst avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.