fully functional api with node and mongodb