- FitLyst is our final project at Makers which is a fitness app which lets you create and track customisable workouts!
- This repository contains the backend node server, we created the frontend in react-native here.
- See our presentation for the app here.
npm ito install dependenciesnpm i --save-dev nodemon- To run the server
npm run dev
- Express
- JsonWebTokens
- bcrypt
- Mongoose Development:
- Nodemon
- Jest
- Supertest
| Endpoint | Functionality | Deployed |
|---|---|---|
| Workout | ||
| POST /workout | Create new workout | ✔️ |
| GET /workout | Returns all workouts | ✔️ |
| GET /workout:id | Return the workout of :id | ✔️ |
| PUT /workout:id | Update the workout of :id | ✔️ |
| DELETE /workout:id | Delete the workout of :id | ✔️ |
| User | ||
| POST /signup | Create new user | ✔️ |
| POST /signin | Authenticates user | ✔️ |
- Example Input for POST /signup and POST /signin (need to provide username and password)
{
"email": "test1@hotmail.co.uk",
"password": "mypassword"
}- Example Input for POST /workout and PUT /workout:id (need to provide workoutTitle and exercises)
{
"workoutTitle": "Upper body",
"exercises": [
{
"title": "Curl",
"duration": 60,
"description": "oof",
"image": "https://upload.wikimedia.org/wikipedia/commons/a/a0/Squat_press_move.jpg"
}
]
}Example output
{
"_id": "609d419518946222fd77dd85",
"workoutTitle": "Upper body",
"exercises": [
{
"_id": "609d419518946222fd77dd86",
"title": "Curl",
"duration": 60,
"description": "oof",
"image": "https://upload.wikimedia.org/wikipedia/commons/a/a0/Squat_press_move.jpg"
}
],
"createdAt": "2021-05-13T15:11:17.726Z",
"updatedAt": "2021-05-13T15:11:17.726Z",
"__v": 0
}Emma Priester | Tarandeep Nandhra | Ralph Bartley | Natalia Sherchenkova