Recipe 101

server test

GET https://server.recipe101.net/

This endpoint allows you to get free cakes.

"server running"

signout

GET https://server.recipe101.net/signout

{
    message:"ok"
}

get recipe info

GET https://server.recipe101.net/recipe/:id

Path Parameters

NameTypeDescription

:id

integer

food_id

{
    data: {
        food_info: {
            id,
            userName,
            foodName,
            summary,
            nation,
            type,
            cookingTime,
            calorie,
            qnt,
            level,
            imgUrl,
            createdAt,
            updatedAt,
        },
        Ingredients: [
            {
                name,
                type,
                cap
            },
            ...
        ],
        Recipes: [
            {
                cookingNo,
                cookingDc,
                stepImage,
                stepTip
            },
            ...
        ],
        Comment:[
            {
                
            },
            ...
        ]
    },
    message: "ok"
}

get userinfo

GET https://server.recipe101.net/user

Headers

NameTypeDescription

authorization

string

access token

{
    data: {
        userinfo: { userName, email, phone, userImage, createdAt },
     },
      meassge: "ok",
}

get subscribed users

GET https://server.recipe101.net/subscribe/:username

Path Parameters

NameTypeDescription

:username

string

username

Headers

NameTypeDescription

authorization

string

access token

{
    users:[
        "name1",
        "name2", 
        ...
        ]
    meassge:"ok"
}

get stored recipes

GET https://server.recipe101.net/store

Headers

NameTypeDescription

authorization

string

access token

{ 
    data:[
        {
            id,
            foodName,
            imgUrl,
            level,
            cookingTime,
            score
        },
        {
            id,
            foodName,
            imgUrl,
            level,
            cookingTime,
            score
        },
        ....
    ],  
    message: "0k" 
}

get comment by username

GET https://server.recipe101.net/comment/user/:username

Path Parameters

NameTypeDescription

:username

string

username

{
    data:[
            {
                    id,
                    foodName,
                    text,
                    score,
                    createdAt,
                    updatedAt
            },
            {
                    id,
                    foodName,
                    text,
                    score, 
                    createdAt,
                    updatedAt

            },
            ...
            
    ],
    meassge:"ok"
}

get comments by food_id

GET https://server.recipe101.net/comment/food/:id

Path Parameters

NameTypeDescription

:id

integer

food_id

{
    data:[
            {
                    id,
                    username,
                    text,
                    score,
                    createdAt,
                    updatedAt
            },
            {
                    id,
                    username,
                    text,
                    score,
                    createdAt,
                    updatedAt
            },
            ...
            
    ],
    meassge:"ok"
}

search recipe using user name

GET https://server.recipe101.net/search/username/:username

Path Parameters

NameTypeDescription

:username

string

username

{
    data: {
        recipes: [
            {
                food_id,
                food_name,
                food_img,
                level,
                cooking_time,
                score
            },
            ...
        ],
    }
    message: "ok"
}

search recipe using food name

GET https://server.recipe101.net/search/foodname/:foodname

Path Parameters

NameTypeDescription

:foodname

string

food_name

{
    data: {
        recipes: [
            {
                food_id,
                food_name,
                food_img,
                level,
                cooking_time,
                score
            },
            ...
        ],
    }
    message: "ok"
}

search recipe using item name

GET https://server.recipe101.net/search/itemname/:itemname&itemname1

Path Parameters

NameTypeDescription

:itemname

string

item_name

&itemname1

string

additional item_name

{
    data: {
        recipes: [
            {
                food_id,
                food_name,
                food_img,
                level,
                cooking_time,
                score
            },
            ...
        ],
    }
    message: "ok"
}

social signin (kakao)

GET https://server.recipe101.net/kakao

Request Body

NameTypeDescription

code

string

authorization_code

{
    accessToken:"accessToken",
    userinfo: { username, email, phone, userimage },
     },
    message:"ok"
}

get image

GET https://server.recipe101.net/image/:name

Path Parameters

NameTypeDescription

name

string

image name

image

recently recipe

GET https://server.recipe101.net/recent/:num

Path Parameters

NameTypeDescription

num

number

number of recipes

{
    data: {
        recipes: [
            {
                food_id,
                food_name,
                food_img,
                level,
                cooking_time,
                score
            },
            ...
        ],
    }
    message: "ok"
}

recommend recipe

GET https://server.recipe101.net/recommend/:num

Path Parameters

NameTypeDescription

num

number

number of recipes

{
    data: {
        recipes: [
            {
                food_id,
                food_name,
                food_img,
                level,
                cooking_time,
                count,
                score
            },
            ...
        ],
    }
    message: "ok"
}

signin

POST https://server.recipe101.net/signin

Request Body

NameTypeDescription

username

string

username

password

string

password

{
    accessToken:"accessToken",
    message:"ok"
}

signup

POST https://server.recipe101.net/signup

Request Body

NameTypeDescription

userName

string

password

string

email

string

phone

string

userImage

string

userimage

{
    accessToken:"accessToken",
    message:"ok"
}

add recipe

POST https://server.recipe101.net/recipe

Headers

NameTypeDescription

authorization

string

access token

Request Body

NameTypeDescription

Food_info

object

cook information include: {foodName, summary, nation, type,cookingTime, calorie, qnt, level}

Ingredients

array

Ingredients for cook include: {name, type, cap}

Recipe

array

how to cook describe step by step include: {cookingNo, cookingDc, stepTip}

foodImage

string

foodimage

stepImage

string

stepimages

{ message: "ok" }

password check

POST https://server.recipe101.net/password

Headers

NameTypeDescription

authorization

string

access token

Request Body

NameTypeDescription

password

string

password

{message:"ok"}

add subscribe

POST https://server.recipe101.net/subscribe

Headers

NameTypeDescription

authorization

string

access token

Request Body

NameTypeDescription

username

string

username

{message:"ok"}

store recipe

POST https://server.recipe101.net/store

Headers

NameTypeDescription

authorization

string

access token

Request Body

NameTypeDescription

id

integer

food_id

{message:"ok"}

create comment

POST https://server.recipe101.net/comment

Headers

NameTypeDescription

authorization

string

access token

Request Body

NameTypeDescription

id

integer

food_id

userName

string

username

comment

string

comment text

score

number

score

{message:"ok"}

update recipe info

PATCH https://server.recipe101.net/recipe/:id

Path Parameters

NameTypeDescription

id

string

update recipe id

Headers

NameTypeDescription

authorization

string

access token

Request Body

NameTypeDescription

Food_info

object

cook information include: {food_name, summary, nation, type,cooking_time, calorie, qnt, level, (option):food_img}

Ingredients

array

Ingredients for cook include: {name, type, cap}

Recipe

array

how to cook describe step by step include: {cooking_no, cooking_dc (option): step_image, step_tip}

foodImage

string

foodimage

stepImage

string

stepimages

{ message: "ok" }

update userinfo

PATCH https://server.recipe101.net/user

Headers

NameTypeDescription

authorization

string

access token

Request Body

NameTypeDescription

userName

string

email

string

phone

string

userImage

string

userimage

{ message: "information updated" }

password update

PATCH https://server.recipe101.net/password

Headers

NameTypeDescription

authorization

string

access token

Request Body

NameTypeDescription

password

string

new password

{message:"ok"}

update comment

PATCH https://server.recipe101.net/comment/:id

Path Parameters

NameTypeDescription

id

integer

comment id

Headers

NameTypeDescription

authorization

string

access token

Request Body

NameTypeDescription

comment

string

comment text

score

number

recipe score

{message:"ok"}

delete recipe

DELETE https://server.recipe101.net/recipe/:id

Path Parameters

NameTypeDescription

:id

integer

food_id

Headers

NameTypeDescription

authorization

string

access token

{ message: "ok" }

delete user

DELETE https://server.recipe101.net/user

Headers

NameTypeDescription

authorization

string

access token

{ message: "He (or She)'s gone" }

Cancel subscription

DELETE https://server.recipe101.net/subscribe/:name

Path Parameters

NameTypeDescription

name

string

userName

Headers

NameTypeDescription

authorization

string

access token

{message:"ok"}

remove stored recipe

DELETE https://server.recipe101.net/store

Path Parameters

NameTypeDescription

food_id

string

food_id

Headers

NameTypeDescription

authorization

string

access token

{message:"ok"}

remove comment

DELETE https://server.recipe101.net/comment/:id

Path Parameters

NameTypeDescription

id

integer

comment id

Headers

NameTypeDescription

authorization

string

acess token

{message:"ok"}

Last updated