added some parameter type checks
added a route for prepopulating the mongo db
added a return statement