https://github.com/webexsamples/simple_service_app
Webex Service App
https://github.com/webexsamples/simple_service_app
Last synced: about 1 year ago
JSON representation
Webex Service App
- Host: GitHub
- URL: https://github.com/webexsamples/simple_service_app
- Owner: WebexSamples
- License: other
- Created: 2023-12-15T20:47:20.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-05-09T18:18:31.000Z (almost 2 years ago)
- Last Synced: 2025-01-07T23:41:10.515Z (about 1 year ago)
- Language: Python
- Size: 13.7 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# webex_service_app
Webex Service App
This Python script allows you to create a meeting on behalf of a subuser in a Webex organization using [service app](https://developer.webex.com/docs/service-apps) credentials.
## Prerequisites
- Python 3.x
- An active Webex account [developer account](https://developer.webex.com/)
- A regisetered service app
## Dependencies
This script depends on the following Python modules:
- requests
- json
- os
- datetime
- webbrowser
You can install these dependencies using pip:
```bash
pip install requests
```
Note: The other dependencies are part of the Python Standard Library and do not need to be installed separately.
## Setup
1. Replace `YOUR CLIENT ID HERE`, `YOUR CLIENT SECRET HERE`, `ACCESS TOKEN POST ADMIN AUTHORIZATION`, `REFRESH TOKEN POST ADMIN AUTHORIZATION` with your own values. These values are produced by registering a service app on Webex Developer Portal @ developer.webex.com.
2. Replace `'A sub users email'` with the email of the subuser for whom you want to create the meeting.
## Running the Script
You can run the script using Python:
```bash
python serviceapp.py
```
This will create a meeting 24 hours from the current time, lasting for one hour. If the access token is invalid and returns a 401 error, the script will automatically refresh the tokens and retry creating the meeting.
Remember to store your tokens securely in a production environment.
## License
This project is licensed under the terms of the MIT license.