

route ( '/incoming', methods = ) def incoming (): logger. Create a server however you like, for example with Flask: from flask import Flask, request, Response app = Flask ( _name_ ) app. Next thing you should do is starting a https server.Īnd yes, as we said in the prerequisites it has to be https server. Call set_webhook(url) with your web server urlĪ simple Echo Bot Firstly, let’s import and configure our bot from viberbot import Api from _configuration import BotConfiguration bot_configuration = BotConfiguration ( name = 'PythonSampleBot', avatar = '', auth_token = 'YOUR_AUTH_TOKEN_HERE' ) viber = Api ( bot_configuration ) Create an HTTPS server.Configure your bot as described in the documentation below.Create a bot and use the authentication token from.Import viberbot.api library to your project.
#Resending viber messages aftee failing install
#Resending viber messages aftee failing how to
Read our blog post on how to test your bot locally. If you deploy on your own custom server, you’ll need a trusted (ca.pem) certificate, not self-signed. Webhook - Please use a server endpoint URL that supports HTTPS.Each request posted to Viber by the account will need to contain the token. Once your account is created your authentication token will appear in the account’s “edit info” screen (for admins only). Account authentication token - unique account identifier used to validate your account in all API requests.This account will automatically be set as the account administrator during the account creation process. An Active Viber account on a platform which supports bots (iOS/Android).This library is released under the terms of the Apache 2.0 license. Please note that Viber is not responsible for promoting your bot. Once you’ve created your bot you are welcome to share it with your Viber contacts or promote it outside Viber on your website or social media channels. Important note for bot developers: Viber’s bot platform is open and free for developers to create bots in our ecosystem.

This package can be imported using pip by adding the following to your requirements.txt: viberbot = 1.0. The library is available on GitHub as well as a package on PyPI. Use this library to develop a bot for Viber platform.
