CRUD functionality for marketplace app containing all routes and requests.
Routes for user and publishers to register, login and reset password.
Route for users to receive a reset password token with an expiry of 10 minutes. The route generates a password token and sends an email to the user.
Key | Value | Description |
---|---|---|
Content-Type | application/json | JSON Type |
Get logged in user via bearer token.
Route for user to login to their account
Key | Value | Description |
---|---|---|
Content-Type | application/json | JSON Type |
Logout currently logged in user
Register a new user/publisher and insert them into the database
Key | Value | Description |
---|---|---|
Content-Type | application/json | JSON Type |
Route to reset user password using reset token
Key | Value | Description |
---|---|---|
Content-Type | application/json | JSON Type |
Logged in user can update their current password. Send in body current password and new password
Key | Value | Description |
---|---|---|
Content-Type | application/json | JSON Type |
Update the details of a registered user in the database
Key | Value | Description |
---|---|---|
Content-Type | application/json | JSON Type |
Route for new products to be posted to
Key | Value | Description |
---|---|---|
Content-Type | application/json | JSON Type |
Delect product using it’s unique I.D.
Get all products available from all users from database
Get all Products from databse that are within a certain radius of a given location to allow users search by area and distance.
Get single product from database using its unique I.D.
Route to allow users upload an image of their product and for that image to be stored in the database
Update product information in the database via a PUT request
Key | Value | Description |
---|---|---|
Content-Type | application/json | JSON Type |
Manage product and user reviews.
Insert review for a specific product
Key | Value | Description |
---|---|---|
Content-Type | application/json | JSON Type |
Delete review as the logged in user who created the review (or admin).
Key | Value | Description |
---|---|---|
Content-Type | application/json | JSON Type |
Get all reviews from database and populate with bootcamp name and description
Get reviews for a product
Get a single review for a product using the reviews I.D.
Update review as the logged in user who created the review (or admin).
Key | Value | Description |
---|---|---|
Content-Type | application/json | JSON Type |
Create Read Update Delete functionality for users only available to admins.
Add user to database while logged in as admin
Key | Value | Description |
---|---|---|
Content-Type | application/json | JSON Type |
Delete user from database while logged in as admin
Get all users while logged in as admin
Get single user by id while logged in as admin
Update user while logged in as admin
Key | Value | Description |
---|---|---|
Content-Type | application/json | JSON Type |