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
import os
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(
os.environ.get('BOT_ENDPOINT'), # bot endpoint from environment
grpc.ssl_channel_credentials(), # SSL credentials (empty by default!)
os.environ.get('BOT_TOKEN') # bot token from environment
)
bot.messaging.on_message(on_msg)
Metadata
Release files for dialog-bot-sdk 2.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| dialog-bot-sdk-2.0.3.tar.gz | 159.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| dialog_bot_sdk-2.0.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 361.2 kB
Release files / dialog-bot-sdk-2.0.3.tar.gz
| Download URL | dialog-bot-sdk-2.0.3.tar.gz |
|---|---|
| Size | 159.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9019d94cf7946392df38714ad1539847035dc1bcf8e34908957c9f0438b0ef25
|
|
BLAKE2b-256 checksum How to use checksums |
97a85460f005d80d9d5eb11c7935544250300475c1da4acb486d68885cb6eff3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.5.0.1 requests/2.20.0 setuptools/40.8.0 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/3.7.1
|
Release files / dialog_bot_sdk-2.0.3-py3-none-any.whl
| Download URL | dialog_bot_sdk-2.0.3-py3-none-any.whl |
|---|---|
| Size | 201.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
040b72a061fba22731ba115db27731cd86de47e5b30b1101cc7a8ccdd6c3f834
|
|
BLAKE2b-256 checksum How to use checksums |
615aaec43bf787866becaaed50acabf49dd72950825d9c28d72d577025eae1a2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.5.0.1 requests/2.20.0 setuptools/40.8.0 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/3.7.1
|