SUPPLIER
GET /supplier/all retorna json com todos os fornecedores
POST /supplier/
{
name: {type: String, required: true},
phone: {type: String, required: true},
}
USER
POST /user/
{
name: {type: String, required: true},
email: {type: String, required: true, unique: true},
password: {type: String, required: true }
}
LOGIN
POST /login/
{
email: {type: String, required: true },
password: {type: String, required: true }
}
retorna
return res.json({
success: true,
token: token,
user: user
});