This project strives to automate the process of publishing events from the D.S.D.A. Blue Suede Shoes website (events page) to several platforms. Notably, the various Google Calendars for different dance styles and danszusjes.nl, Unilife, and Facebook.
The project is in reasonable usability and documentation state, but not super robust against errors.
Technical note
Firefox is used as platform for the web automations by Selenium. Have it installed, or change the settings and get the driver for the browser you want.
Get a Python environment, e.g. a virtual one:
python -m venv ./venv
Install the requirements
pip install -r requirements.txt
Get the authentication information for the various platforms. Likely an existing config can mostly be reused by someone else.
- Google Calendar: Get credentials as explained here. Get a
credentials.json
file, rename togoogle_api_credentials.json
. - Unilife: Email address and password in
credentials.json
. - Facebook:
- Email address, password, and two-factor authentication info (OTP)
- A token for the Graph API. See "Before You Start" on the getting started page.
This token must be transformed to a long-lived (page) token. This can be done with theget_long_lived_token
function in facebook_adapter.py. For this you also need the Facebook app id and secret. - These also in
credentials.json
.
Example credentials.json
{
"FACEBOOK_ID": "",
"FACEBOOK_PASSWORD": "",
"FACEBOOK_TOTP": "",
"UNILIFE_ID": "",
"UNILIFE_PASSWORD": "",
"FACEBOOK_GRAPH_API_TOKEN": "",
"FACEBOOK_APP_ID": "",
"FACEBOOK_APP_SECRET": ""
}
Run the Python program.
./venv/Scripts/activate
python main.py
The terminal will guide you through the process.