Skip to content

Zmat24/server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Zmat24 Fake REST Api

a lightweight lib for fake REST Api & full of features

Features

  • Zero Config
  • Zero dependency
  • Schema base
  • Auth
  • Middleware
  • Database support
  • Crud ready
  • Support freamwork
  • use Bun

Install & Setup

soon

Usage/Examples

// schema.config.js
const config = {
    storage: "json", // or database
    schemas: {
        user: {
            // controll endpoints
            endpoints: {
                create: true,
                view: true,
                update: true,
                delete: false,
            },
            // controll auth
            auth: {
                type: "jwt"
            },
            // controll field
            fields: {
                name: {
                    // validation
                    validation: "required|min:3"
                },
                email: {
                    validation: "required|max:50"
                },
                password: {
                    validation: "required|min:8",
                    // hash or scurty
                    hash: true,
                }
            }
        },
    },
};

export default config;

Authors

Support

For support, email [email protected] or join our Telegram Channel.

About

a lightweight lib for simple REST Api

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published