Book classes programatically so you can sleep
You need phantommjs installed for this to run - install with
npm install phantomjs -g
Variable | Description |
---|---|
USERNAME |
Username used to login to Gymbox |
PASSWORD |
Password used to login to Gymbox |
SCHEDULE |
JSON schedule for the classes to book |
The schedule JSON uses days of the week as root-level keys which contain an array of classes. Each class has a Name
key which is the name of the class and a StartTime
key which is the 24hr class time
{
"Tuesday": [
{
"Name": "Bike & Beats",
"StartTime": "07:00"
},
{
"Name": "Tour De Victoria",
"StartTime": "12:00"
}
],
"Thursday": [
{
"Name": "Hatha Yoga",
"StartTime": "13:00"
},
{
"Name": "Ripped & Stripped",
"StartTime": "17:30"
}
]
}