/healert-rest-api

Healert rest api

Primary LanguageJavaScript

hapijs-mongoose-restapi

This is a boilerplate for creating a RESTful API using hapi.js and mongoose. The code for creating the API has been explained in this Medium Post

bitHound Dependencies Known Vulnerabilities Build Status CircleCI XO code style Coverage Status

Directory Layout

.
├── app.js                  // App and Entry Point
├── /config/database.js             // MongoDB Connection
├── /controllers/                // Controllers
├── /helpers/                // Helper code
├── /models/                // DB Models
│   └── Wolf.js             // Schema
├── /routes/                // DB Models
│   └── wolves.js           // Routes
├── /services/                // Services
├── /test/                // Tests
├── /node_modules/          // Project Dependencies[pm modules]
├── package.json
└── yarn.lock

Getting Started

docker-compose up --build

This will watch for changes and restart

Open Dev Console in another terminal

docker-compose exec nodejs sh

Example routes

GET

POST


Made with ♥ by Healert team