No description, website, or topics provided.
Clone or download
Latest commit d64bd89 Dec 3, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
node_modules finished Dec 3, 2019
READme.md Update READme.md Dec 3, 2019
database.db finished Dec 3, 2019
database.js finished Dec 3, 2019
index.js finished Dec 3, 2019
package-lock.json finished Dec 3, 2019
package.json finished Dec 3, 2019
seed.js finished Dec 3, 2019
server.js finished Dec 3, 2019

READme.md

Workout API

This API allows you to document which muscles could be trained with which workout variation.

Workout Variations

/api/workout_variation

GET

Will get all workout variations from the workout_variation table

/api/workout_variation/:id

GET

Will get a specific workout variation from the workout_variation table by id

/api/workout_variation

POST

Will add a workout variation to the workout_variation table

/api/workout_variation/:id

PUT

Will update a specific workout variation from the workout_variation table by id

api/workout_variation/:id

DELETE

Will delete a specific workout variation from the workout_variation table by id

Muscles

/api/muscles

GET

Will get all muscles from the muscle table

/api/muscles/:id

GET

Will get a specific muscle from the muscle table by id

/api/muscles

POST

Will add a muscle to the muscle table

/api/muscles/:id

PUT

Will update a specific muscle from the muscle table by id

api

DELETE

/muscles/:id Will delete a specific muscle from the muscle table by id

Many-to-Many

(Used postman to create this relationship)

Workout_Muscle

/api/workout_muscle

GET

Will get all the workout variations that includes the muscle with the specified muscle id

/api/workout_muscle/:id

GET

Will get one workout variation that includes the muscle with the specified muscle id

/api/workout_muscle

POST

Will add a new relationship between muscle_id and workoutVariation_id

/api/workout_muscle/:id

PUT

Will update a workout variation that includes the muscle with the specified muscle id

api/workout_muscle/:id

DELETE

Will delete a workout variation that includes the muscle with the specified muscle id