Back-end repo for replate2 deployed Link is:
-
- Logs a Business User In
- Registers a New Business User
- Edit Business Profile
- Delete Business Profile
- Create Food Request for Business to include: Type, Amount/Servings, Preferred Pick-up Time
- Add New Food Request for Business
- Updates Food Request for Business based on provided Id
- Deletes Food Request for Business based on provided Id
-
- Logs a Volunteer User In
- Registers a New Volunteer User
- Updates the Volunteer profile
- Deletes the Volunteer profile
- View List of All Unassigned/Pending Food-Requests
- Click on Food Request to view more info
- Accept and Complete Food Request
- Cancel the assigned food request the Volunteer is signed up for
- Mark assigned pickup as complete
Logs a Business User In
POST /api/businesses/login
Name | Type | Description |
---|---|---|
username | String | Username of the User |
password | String | Password of the User |
Success-Response:
[ { "username": "nick", "name": null, "address": null, "phone": null, "email": null } ]
{ "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWJqZWN0IjoxLCJ1c2VybmFtZSI6Im5pY2siLCJyb2xlIjoiZG9uYXRvciIsImlhdCI6MTU4MDg2ODI4MSwiZXhwIjoxNTgxNDczMDgxfQ.Rxg7V9AsxWXXxGtpSQONvrTRwYrNm1H7-d7UosgC8bE", "message": "Welcome nick!" }
Invalid--credentials-please-try-again
{ message: "Invalid credentials, please try again."}
Registers a New Volunteer
POST /api/businesses/register
Name | Type | Description |
---|---|---|
username | String | The New Business Users username *Required |
password | String | The New Business Users password *Required |
name | String | The New Business Users name |
address | String | The New Business Users address |
phone | String | The Users Business phone |
String | The New Business Users email |
Success-Response:
{ "username": "nick", "name": null, "address": null, "phone": null, "email": null }
Logs an Volunteer In
POST /api/volunteers/login
Name | Type | Description |
---|---|---|
username | String | Username of the User |
password | String | Password of the User |
Success-Response:
{ "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWJqZWN0IjoxLCJ1c2VybmFtZSI6Im5pY2siLCJyb2xlIjoidm9sdW50ZWVyIiwiaWF0IjoxNTgwODY4OTYzLCJleHAiOjE1ODE0NzM3NjN9.y6u3ZD1wCc_6MhpCDXVNRElpQYEpHeLHA-hvtriJoRQ", "message": "Welcome nick!" }
Invalid--credentials-please-try-again
{ message: "Invalid credentials, please try again."}
Registers a New Volunteer User
POST //api/volunteers/register
Name | Type | Description |
---|---|---|
username | String | The New Business Users username *Required |
password | String | The New Business Users password *Required |
name | String | The New Business Users name |
phone | String | The Users Business phone |
Success-Response:
{ "name": null, "phone": null }