TGPy
Run Python code right in your Telegram messages. TGPy is a tool built on top of Telethon.
- Calculate right in chats
- Send messages, save files, analyze chats — with simple code
- Set up functions to automate your Telegram actions
Basics Guide · Extensibility Guide · Reference
Getting started
Python 3.9+ required. Install TGPy and connect it to your Telegram account:
> pip install tgpy
> tgpy
You’re ready now. Send Python code to any chat, and it will run. Change your message to change the result.
Inspiration
TGPy is inspired by FTG and similar userbots. However, the key concept is different: TGPy is totally based on usage of code in Telegram rather than plugging extra modules. This leads both to convenience of single-use scripts and reusage flexibility.
Credits
TGPy is built on Telethon, which allows to integrate Telegram features in Python code.
Basic code transformation (such as auto-return of values) is based on meval.
License
This project is licensed under the terms of the MIT license.
Metadata
Release files for tgpy 0.6.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| tgpy-0.6.1.tar.gz | 17.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| tgpy-0.6.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 38.6 kB
Release files / tgpy-0.6.1.tar.gz
| Download URL | tgpy-0.6.1.tar.gz |
|---|---|
| Size | 17.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e47db850b2ad5482cc5a63b5b5bd70a692887640da2f80f3a5df2032ea0860fe
|
|
BLAKE2b-256 checksum How to use checksums |
5833c751baca4a200899d8db7fc6152b3edb5f4b8a5c22d22f11ac77ccdc521d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.8.0 pkginfo/1.8.3 readme-renderer/36.0 requests/2.28.1 requests-toolbelt/0.9.1 urllib3/1.26.11 tqdm/4.64.0 importlib-metadata/4.12.0 keyring/23.8.2 rfc3986/2.0.0 colorama/0.4.5 CPython/3.10.9
|
Release files / tgpy-0.6.1-py3-none-any.whl
| Download URL | tgpy-0.6.1-py3-none-any.whl |
|---|---|
| Size | 21.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f480a1cf72f52ab0cf41e62a8ec2f7b21d448af1a00b9c906cf88df0fea59438
|
|
BLAKE2b-256 checksum How to use checksums |
1f866f2d55a36f379ef8741918e3ce89fbb278c5bb2648b489d16c2aa6462961
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.8.0 pkginfo/1.8.3 readme-renderer/36.0 requests/2.28.1 requests-toolbelt/0.9.1 urllib3/1.26.11 tqdm/4.64.0 importlib-metadata/4.12.0 keyring/23.8.2 rfc3986/2.0.0 colorama/0.4.5 CPython/3.10.9
|