Update server.js

Added service to add to and read from mongodb