A Node.js CLI utility to retrieve available time slots on your Google Calendar.
- Node.js & NPM
- Knowledge of Google API's (e.g., ability to create an application in Google Developer Console, add an API, generate OAuth Credentials)
Running this application for the first time:
- Follow this tutorial to generate a Google Calendar API: https://github.com/matthewvolk/amifree/tree/master/docs/oauth-tutorial
$ git clone https://github.com/matthewvolk/amifree.git amifree/
$ cd amifree/
$ npm install
$ bin/amifree setup
When the application is complete, the user will be able to:
npm install amifree
- Application lists out steps to generate an appropriate Google OAuth application, read credentials.json file, and asks you for the Google Calendar ID of the calendar you want to read.
amifreefor a list of available time slots from the Google Calendar associated with the Google Calendar ID above.
- Refactor to use Moment.jss
credentials.jsonfile already exists and user runs
amifree setup, ask "Would you like to overwrite your current credentials file?"
amifree --this week: As well as other commands like this, I want the user to be able to query their calendar for a wider range of dates
amifree --changeCalendarID firstname.lastname@example.org: Allows user to change the Google Calendar ID you want to read from.
- Right now, all users are forced to create their own Google API credentials for this project. I'm not sure there's any better way to do this given the way that OAuth 2.0 is written, but any and all PR's are welcome.
- I thought I could make a solution without Moment.js, but turns out Moment.js just has too many useful utils that I could incorporate.