auliahanifan / express-mongo-auth

Implementation of authentication and authorization using mongodb and expressjs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

express-mongo-auth

Schemas

User Schema

{
    username: {
        type: String,
        index: true,
        unique: true
    },
    password: {
        type: String
    },
    role: {
        type: String,
        enum: ['ADMIN', 'COMMON']
    },
}

Data Seeder

Here are the data that already exist when running this project.

ADMIN
username = admin
password = admin

USER
username = user
password = user

Diagrams

Login Flow

Login Flow

CRUD Flow

CRUD Flow

Kubernetes

Deployed Well

K8s

Test Endpoint

API

API Docs

Postman Collection

About

Implementation of authentication and authorization using mongodb and expressjs


Languages

Language:TypeScript 98.7%Language:Dockerfile 0.6%Language:Shell 0.6%