API untuk toko online
- POST
/register/
-- User registrations - POST
/auth/
-- admin authentication - GET
/me
-- get current logged user - GET, POST
/admin/product
-- product management (CRUD product) - GET, PUT, DELETE
/admin/product/:id
-- get product by ID or update/delete product by ID - GET
/admin/transactions
-- transaction list made by user/customer - POST, GET
/cart
-- customer cart (list product in customer cart) - POST
/checkout
-- customer checkout (trx, payment) - GET
/transactions/
-- list of transaction that user made
-
URL:
/register
-
Method:
POST
-
Body:
{ "name": "John Doe", "email": "[email protected]", "phoneNumber": "123", "password": "123" }
Response:
{
"error": false,
"message": "User berhasil daftar"
}