Skip to content

Admin Panel API to add / modify / read / delete companies and their employees

Notifications You must be signed in to change notification settings

Saba-Var/company-employees-api

Repository files navigation

Admin Panel API

Using the Admin Panel API you can add / modify / read / delete companies and their employees

Table of Contents

Prerequisites

  • Node JS @12.X and up

  • npm @6 and up

Tech Stack

Getting Started

1. First of all you need to clone repository from github:

git clone https://github.com/Saba-Var/company-employees-api.git

2. Next step requires install all the dependencies

npm install

or

yarn install

3. Copy .env

cp .env.example .env

4. If you want you can also change default configuration of .env file and connect to mongodb

MONGO_DATABASE=adminPanel
MONGO_PROTOCOL=mongodb
MONGO_HOST=localhost
MONGO_PORT=27017
MONGO_CLUSTER=''

SERVER_PORT=3000

ACCESS_TOKEN_SECRET=secret-text

USER_PASSWORD=***
USER_EMAIL=***

5. after that you can run Admin Panel API from terminal:

npm run dev

6. To create new user from the terminal run the following command:

npm run user:create

To see swagger documentation visit localhost:3000/api-docs/

Project Structure

├─── readme
├─── src
│    ├── bin
│    ├── config
│    ├── controllers
│    ├── middlewares
│    ├── models
│    ├── routes
│    └── schemas
- .env
- .eslintrc.json
- .gitignore
- .prettierrc.json
- package.json
- README.md

Resources

About

Admin Panel API to add / modify / read / delete companies and their employees

Topics

Resources

Stars

Watchers

Forks