To run the service:
$ node main.js
The service endpoint is http://localhost:8082/
The default credentials are username: testuser
, password: testpass
.
The code is laid out as follows:
main.js
- entry point for the programdispatcher.js
- dispatches HTTP requests for APIs and/or static dataapi/{name}.js
- handles HTTP requests of the form/api/{name}/...
static/
- static HTML data served for non-API requestsservice/*.js
- tools and libraries called by dispatcher and APIssessions/
- logged-in user sessions (if any)data/
- API data storageusers.json
- list of username and sha256(passwords)test.js
- script to run unit teststests/
- unit tests