-
Notifications
You must be signed in to change notification settings - Fork 1
User
Leeyoujin edited this page Feb 21, 2021
·
4 revisions
user profile 확인 및 수정
[req] GET /user/:user_id (ex : /user/3)
header : {
authorization: token(string)
}
[res]
status code : 200
{
"msg": "user profile",
"info": {
"email": "[email protected]",
"name": "test",
"birth": "2021-02-10T15:00:00.000Z",
"death": "2021-03-04T15:00:00.000Z",
"profile_image": "http://localhost:3001/upload/2021-02-21/20210221114000_스크린샷(1).png",
"profile_detail": "test"
}
}
status code : 400
{
'msg':`Invalid user id`
}
[req] PUT /user/update
header : {
authorization: token(string)
}
body : {
name : (string)
birth : (date)
death : (date)
profile_image : (file) // 나중에 구현
profile_detail : (string)
}
[res]
status code : 200
{
msg : 'profile update success'
}
status code : 400
{
'msg':`Invalid user id`
}
[req] GET /user/getid
header : {
authorization: token(string)
}
[res]
status code : 200
{
"user_id" : user_id(int)
}
status code : 400
{
'msg':`Invalid user token`
}