0.2.2 • Published 5 years ago
@oriient/services-routes v0.2.2
@oriient/services-routes
The package expose http routes of services inside oriient system in order other services will not need to hard code the route.
Usage
All the routes are exposed using a function you should call. Some of the routes accept parameters like in the example below:
Since the add chunk route has param in path (/v1/records/:sessionId/add-chunk) we supply the session id to get formatted route.
const routes = require('@oriient/services-routes');
let mongodbServiceAddRecordRoute = routes.mongodbServiceRoutes.addChunk('mysessionId');
console.log(mongodbServiceAddRecordRoute);// /v1/records/mysessionId/add-chunk