Pure Python 3 MTProto API Telegram client library, for bots too!
Go to file
Lonami 06832f8108 Implemented init and write code on TLObjects Generator
The code generated by the generator now classifies the output files
in their corresponding categories, also writing their __init__(...)
with documented arguments, and the on_send(...) method
2016-08-27 11:59:23 +02:00
network Implemented init and write code on TLObjects Generator 2016-08-27 11:59:23 +02:00
parser Implemented init and write code on TLObjects Generator 2016-08-27 11:59:23 +02:00
requests Initial release 2016-08-26 12:58:53 +02:00
tl Implemented init and write code on TLObjects Generator 2016-08-27 11:59:23 +02:00
utils Implemented init and write code on TLObjects Generator 2016-08-27 11:59:23 +02:00
.gitignore Added a .tl file tokenizer and parser 2016-08-26 19:12:20 +02:00
LICENSE Initial release 2016-08-26 12:58:53 +02:00
main.py Implemented init and write code on TLObjects Generator 2016-08-27 11:59:23 +02:00
README.md Implemented init and write code on TLObjects Generator 2016-08-27 11:59:23 +02:00
scheme.tl Implemented init and write code on TLObjects Generator 2016-08-27 11:59:23 +02:00
tlobjects_generator.py Implemented init and write code on TLObjects Generator 2016-08-27 11:59:23 +02:00

Telethon

Telethon is Telegram client implementation in Python. This project's core is completely based on TLSharp, so please, also have a look to the original project!

Other parts, such as the request themselves, the .tl tokenizer and code generator, or some ported C# utilities such as BinaryWriter, BinaryReader, TCPClient and so on, are no longer part of TLSharp itself.

Requirements

This project requires the following Python modules, which can be installed by issuing sudo -H pip install <module> on a Linux terminal:

We need your help!

As of now, the project is fully untested and with many pending things to do. If you know both Python and C#, please don't think it twice and help us (me)!

Code generator limitations

The current code generator is not complete, yet adding the missing features would only over-complicate an already hard-to-read code. Some parts of the .tl file should be omitted, because they're "built-in" in the generated code (such as writing booleans, etc.).

In order to make sure that all the generated files will work, please make sure to always comment out these lines in scheme.tl (the latest version can always be found here):

// boolFalse#bc799737 = Bool;
// boolTrue#997275b5 = Bool;
// true#3fedd339 = True;
// vector#1cb5c415 {t:Type} # [ t ] = Vector t;