Scheduler API is a generic scheduling REST API written in Node/Express. Some conventions that it enforces include:
- allow an infinite number of appointments in a day but only allow a maximum of one appointment per user per day,
- allow appointments only on the hour or half-hour
- use UTC throughout in requests and responses
To get the API up and running, you have the option to either run this project as a Docker image or in your own node.js environment.
- install docker on your local machine
- open a command line and type the following command
docker run --rm -p 8000:8000 mattcameron/maven_scheduler
- install the LTS version of node
- from the project root, type the following series of commands:
-
npm install
-
node server.js
Verify that the app is up and running by navigating to localhost:8000 in your browser. You should see a message saying "Success, the API is up and running!"
The below endpoints will be prefixed by localhost:8000
.
- List Appointments for User :
GET /appointments/:userId
- Schedule Appointment for User :
POST /appointment