Running the Bot (Questions)
Output
As a first time speaker I thought using WebEx to expand the interactivity and longevity of my sessions I wrote this bot. I wanted to share with other Speakers in case they wanted to use it for their sessions.
To get started with CLUS_2022 WebEx Bot, follow the steps below:
In WebEx create and customize a room for your session
Visit the following developer.webex.com URL to get the room ID: List_Rooms
Click the copy button to obtain a 24-hour token. This token will be used to access the room. Keep it safe and secure. I recommending using environment variables to store the token so you do not have to input it everytime you run the bot.
Next get the room ID for the room you created. You need this to pass messages into the room with the bot. You can get the room ID in the browser directly or with a tool like Postman.
After you have the token and Rooms URL you can use Postman to get your rooms as well. Make a new GET request to the rooms URL. Specify Bearer token as the Authorization Type and paste in your token. Save this request if you would like in a Collection for reuse.
To install the bot there are a few simple steps:
The following instructions are based on Windows WSL2 and Ubuntu however any flavour of Linux will work with possibly slightly different commands.
$ python3 -V
Python 3.9.10
$ sudo apt install python3-venv
$ python3 -m venv message_room
$ source message_room/bin/activate
(message_room)$
(message_room)$pip install pywebexmessage
C:\>python3 -m venv message_room
C:\>message_room\Scripts\activate
(message_room) C:\>
(message_room)$pip install pywebexmessage
(message_room)$ message_room
Every question can be stored as a variable in the environment. This is useful if you want to reuse the same question in multiple messages.
Linux: export ROOMID=
export TOKEN=
export IMAGE=
export HEADER=
export TITLE=<title>
export DESCRIPTION=
export LOCATION=
export DATE=
export TIME=
export SPEAKERS=
export URL=
export URL_LABEL=<url_label>
Windows: set ROOMID=
set TOKEN=
set IMAGE=
set HEADER=
set TITLE=<title>
set DESCRIPTION=
set LOCATION=
set DATE=
set TIME=
set SPEAKERS=
set URL=
set URL_LABEL=<url_label>