Welcome to python-telegram’s documentation¶
Client for the tdlib library.
Installation¶
First you need to install tdlib
.
How to build tdlib¶
After building the library, you need to install it:
make install
Library installation¶
This library requires Python 3.9 or higher.
python3 -m pip install python-telegram
Next, you need to register a new Telegram application.
Now you can start using the library: Tutorial.
Note
More examples can be found here.
Note
The tdlib
binary for Linux provided by python-shortcuts
has been built on Ubuntu with libc strating from version 0.10.0
. Versions before 0.10.0
were built on Alpine Linux with musl
.
Docker¶
A Docker image for this library is available here
docker run -i -t --rm \
-v /tmp/docker-python-telegram/:/tmp/ \
akhmetov/python-telegram \
python3 /app/examples/send_message.py $(API_ID) $(API_HASH) $(PHONE) $(CHAT_ID) $(TEXT)