- NodeJS
- NPM
- Couchbase Server
Clone this repository to your desktop or any preferred location.
Using the command prompt (Windows) or Terminal (Mac / Linux) navigate to the cloned directory and run:
npm install
This will install all the required application dependencies such as the Couchbase SDK and Express framework.
Open config.json at the root of the project and validate that the default global configuration settings look accurate.
When ready to test the application, using the command prompt (Windows) or Terminal (Mac / Linux), run:
node app.js
This will make the application accessible at http://localhost:3000
Create a new user account on the server
None
parameter | description |
---|---|
username | username to access the account |
password | password for accessing the account |
name | account owners name |
Get user information about the currently signed in user
header | description |
---|---|
authorization | bearer token |
None
Trade user credentials for a session id to be used with further requests against protected endpoints
None
parameter | description |
---|---|
username | username to access the account |
password | password for accessing the account |
file / folder | parent | description |
---|---|---|
routes | root | all application endpoint routes will end up in here |
routes.js | routes | all endpoint routes |
models | root | all database classes will end up in here |
accountmodel.js | models | class for crud operations on user accounts |
sessionmodel.js | models | class for crud operations on user sessions |
app.js | root | server initialization code |
config.json | root | server and database configuration information |