This lib for sending message to tg bots
Project description
Python
How to install ?
pip install tg-bot-sender
Imports
from tg_bot_sender import Data, TelegramSender
Getting started
The logs parameter indicates that logs are saved in json format
tg = TelegramSender(telegramToken, logs = False)
Response structure
{ "amount": 0 } // number of messages sent
Options for sending messages
sendFromIds - sending to users
tg.sendFromIds([...telegramUserIds], Data(
text = 'Hello',
photo = 'Photo link',
buttons = [{
buttonTitle: 'Hello',
buttonUrl: 'https://google.com'
}]
))
sendFromId - sending to the user
tg.sendFromIds(telegramUserId, Data(
text = 'Hello',
photo = 'Photo link',
buttons = [{
buttonTitle: 'Hello',
buttonUrl: 'https://google.com'
}]
))
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
tg_bot_sender-0.6.tar.gz
(3.0 kB
view details)
File details
Details for the file tg_bot_sender-0.6.tar.gz.
File metadata
- Download URL: tg_bot_sender-0.6.tar.gz
- Upload date:
- Size: 3.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.8.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2258f0a408f80c5cf6b5d743306b3b4608fb59469af7a64a519c82f755ffe26a
|
|
| MD5 |
bbcc758967b70a8491d3b029622ce9d0
|
|
| BLAKE2b-256 |
042ad84c623551bb0316a1c7f4034bfba59cc2e8c85b17897850461e7811abe7
|