Skip to content

[POST] 국,찌개

chlrkdgml11 edited this page Mar 3, 2021 · 4 revisions

URL

/api/diets/postSoupDiets

REQUEST

key type description remark
users_age int
expectedDate str
riceDietName str
swipeSoup arr

REQUEST BODY

{
    "users_age" : 25,
    "expectedDate" : "2021-09-06T00:00:00.000Z",
    "riceDietName" : "오곡밥",
    "swipeSoup" : []
}

RESPONSE BODY

실패

{
    returnJson.res_state = "sql_error";
    returnJson.res_msg = "잠시 후에 시도해주세요.";
}

성공

{
    "res_state": "success",
    "res_msg": "국을 가져왔습니다.",
    "res_data": {
        "soup": {
            "_id": "603f3e13b1f563498e76d054",
            "idx": 7289,
            "dietName": "콩나물된장찌개",
            "group": "국",
            "classification": "채소류찌개.전골",
            "serving": 200,
            "kcal": 97.33333333,
            "protein": 5.133333333,
            "calcium": 39.04666667,
            "ferrum": 0.886666667,
            "phosphorus": 122.18,
            "zinc": 0.726666667,
            "selenium": 12.75333333,
            "vitamin_B1": 0,
            "vitamin_B2": 0.22,
            "folate": 40.58,
            "vitamin__C": 21.95333333
        }
    }
}
Clone this wiki locally