Python Bot SDK for Dialog Messenger
Project description
Dialog Python Bot SDK
Python Bot SDK for Dialog messenger.
Full documentation is available here.
Usage
from dialog_bot_sdk.bot import DialogBot
import grpc
def on_msg(*params):
bot.messaging.send_message(
params[0].peer, 'Reply to : ' + str(params[0].message.textMessage.text)
)
if __name__ == '__main__':
bot = DialogBot.get_secure_bot(
'grpc-test.transmit.im:9443', # bot endpoint
grpc.ssl_channel_credentials(), # SSL credentials (empty by default!)
'cbb4994cabfa8d2a5bce0b5f7a44c23da943f767' # bot token
)
bot.messaging.on_message(on_msg)
License
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
dialog-bot-sdk-1.0.1.tar.gz
(157.5 kB
view hashes)
Built Distribution
dialog_bot_sdk-1.0.1-py3-none-any.whl
(200.1 kB
view hashes)
Close
Hashes for dialog_bot_sdk-1.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a153d70d9eadddadb1880c22d18f88804038fbd66efb10bdede2ee4217200ba7 |
|
MD5 | a8a5b2a6695180ea8edd7aca2520bd75 |
|
BLAKE2b-256 | ace531aa681964c697d8cc1b92ab45dd41d6a75c0e28753f9a2e760fa6515e5b |