As stated previous, the server is programmed in NodeJS. So I have my a directory in my home directory called HealthServer:

  • mkdir ~/HealthServer

Inside here, I’ve installed the required libraries:

  1. sudo apt-get install npm
  2. npm install bson
  3. npm install express
  4. npm install mongodb

This will create a directory called node_modules with the following directories inside:

  • bson
  • express
  • mongodb

Courtesy of Christophe Coenraets, we can make the following paths for the NodeJS server:

  • We can see, the initial server allows us to do the following:
    • Find all patients (I’ve added one in manually to MongoDB)
    • Find a specific patient
    • Find all pulse readings for a specific patient
    • Add a pulse reading for a specific patient


As well as making the following connection to the database:


And defining the GET and POST functions: