Project description link
- EDP API:
- EDP Frontend:
For searching and filter all GET all endpoints access the following query params:
-
search: which is a text you are trying to search
-
Page: page number form 1 to ...
-
Limit: which is the size of results to be returned per page
example:
/sales?page=2&limit=15&search=FAB
POST /authentication/sign-in
{
"Content-type": "application/json"
"body":{
"phoneNumber":"0789374675",
"password":"string345"
}
}
GET /authentication/current
{
"Content-type": "application/json"
"Authorization":{{TOKEN}}
}
POST /users
(for admin)
POST /companies/:companyId/users
(for supervisor)
{
"Content-type": "application/json"
"Authorization":{{TOKEN}}
"body":{
"username":"abayo",
"password":"password",
"phoneNumber":"0789277287",
"companyId":"6faa1986-d9c9-42ab-a40e-477c1124581f"
}
}
GET /users
(for admin)
GET /companies/:companyId/users
(for supervisor)
{
"Content-type": "application/json"
"Authorization":{{TOKEN}}
}
GET /users/:id
(for admin and owner)
GET /companies/:companyId/users/:id
(for supervisor)
{
"Content-type": "application/json",
"Authorization":{{TOKEN}}
}
PUT /users/:id
{
"Content-type": "application/json",
"Authorization":{{TOKEN}}
"body":{
"name":"Luc Abayo",
"username":"abayo_luc",
"email":"me@gexample"
}
}
PUT /users/:id/passwords
{
"Content-type": "application/json",
"Authorization":{{TOKEN}}
"body":{
"password":"new-password"
}
}
POST /companies
{
"Content-type": "application/json"
"Authorization":{{ADMIN_TOKEN}}
"body":{
"name":"123 Inc.",
"email":"[email protected]",
"address":"KG 11 Av",
"phoneNumber":"0789277275"
}
}
GET /companies
{
"Content-type": "application/json"
"Authorization":{{TOKEN}}
}
GET /company/:id
{
"Content-type": "application/json",
"Authorization":{{TOKEN}}
}
PUT /companies/:id/passwords
{
"Content-type": "application/json",
"Authorization":{{TOKEN}}
"body":{
"name":"EDP Ltd",
"email":"[email protected]",
"address":"GG 11 St",
"phoneNumber":"0789866365"
}
}
DELETE /companies/:id
{
"Content-type": "application/json",
"Authorization":{{TOKEN}}
}
GET /sales
(for only admins)
{
"Content-type": "application/json",
"Authorization":{{TOKEN}}
}
GET /companies/:companyId/sales
GET /companies/:companyId/