This is my self-study project to learn how to build REST API with Node/Express.js. The ambition is to create something like a recipe social platform where people can share recipes, follow other users etc.
nodemon server.js
GET
/api/v1/recipes
GET
/api/v1/recipes/:recipeId
POST
/api/v1/recipes
Request body:
{
name: String,
description: String,
ingredients: [
{
name: String,
amount: Number,
unit: String
}
],
instructions: String,
duration: Number,
public: Boolean
}
PUT
/api/v1/recipes/:recipeId
Request body: same as Create recipe
DELETE
/api/v1/recipes/:recipeId
PUT
/api/v1/recipes/:recipeId/photo
POST
api/v1/auth/register
POST
/api/v1/auth/login
GET
/api/v1/auth/me
GET
/api/v1/auth/logout