upload files to your telegram channel or group with your telegram bot
Project description
t-bot
Upload files to your Telegram channel or group with your telegram bot
Features
- Progress bar
- You can change file name before upload on telegram
Note : Bot can upload only 50 MB file (with default telegram bot api server url)
Installation
pip3 install tl-bot
Usage
t-bot setup # setup your telegram credentials
t-bot reset # reset to default your telegram credentials
t-bot test # test telegram bot token
t-bot getid # get chat id of your connected group or channel
t-bot up {file_name} -c file_caption # upload Telegram channel or group
t-bot d {url} -c caption # download and upload file to your Telegram channel or group
API
The anonfile-upload client is also usable through an API (for test integration, automation, etc)
tl_bot.main.test_token(bot_token)
from tl_bot.main import test_token
test_token(bot_token) # bot_token type str
tl_bot.main.uploadd_file(bot_token, chat_id, file_name, caption)
from tl_bot.main import uploadd_file
uploadd_file(bot_token, chat_id, file_name, caption) # all arguments must be str
tl_bot.main.download(url:str, bot_token:str, chat_id:str, caption:str=None)
from tl_bot.main import download
download(url, bot_token, chat_id, caption) # all arguments must be str
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
tl-bot-0.0.5.tar.gz
(7.1 kB
view details)
Built Distribution
File details
Details for the file tl-bot-0.0.5.tar.gz
.
File metadata
- Download URL: tl-bot-0.0.5.tar.gz
- Upload date:
- Size: 7.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1a5ad7d4fde903ff300e6d2c288bdf7b8cd91f3106004cce1c59050d6cba6ae7 |
|
MD5 | adf669aded324ec7809970ede21b9ca9 |
|
BLAKE2b-256 | c43279cd8a36f0783692dce87686eced3ca0369571692a8243b7ab8ca656824a |
Provenance
File details
Details for the file tl_bot-0.0.5-py3-none-any.whl
.
File metadata
- Download URL: tl_bot-0.0.5-py3-none-any.whl
- Upload date:
- Size: 7.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e7975e7907529b73786b5d4fa187020ba21e8cd4ca2dfffbdd135e3af7c2d70a |
|
MD5 | 5cee50c9c3dd4c42df69cb8b06b5e4e2 |
|
BLAKE2b-256 | b52bb5afe7f1e1cabde92b88bddbd33b67ab6457118048c771d43254267cf4ac |