update user_info: 更新 使用者額外 資料 07-12 15:26
update user_info: 更新 使用者額外 資料
更新時間:2022-07-12 15:26:49
如果要更新user table的資料, 如: user.email
請call user_update
HTTP Request
POST: manager/user_info/update/:id
URL Parameters
Parameter | Type | Status | Description |
---|---|---|---|
id | int | required | user_info.id |
Body Parameters
Parameter | Type | Status | Description |
---|---|---|---|
data | object | optional | |
user_id | int | optional | user_info.id |
avatar | string | optional | user_info.avatar |
Response Structure
Parameter | Type | Status | Description |
---|---|---|---|
status | int | required | 0: 成功, 非0: 失敗 |
data | object | optional |
Example usage
Example #1
POST: manager/user_info/update/1
Body
{
"data": {
"user_id": 167,
"avatar": "https://via.placeholder.com/128"
}
}
Response(200,status=0)
{
"status": 0
}
Example #2
POST: manager/user_info/update/99999
Response(200,status=404 Not Found.)
{
"status": 404,
"error": "Not found."
}
Example #3
POST: manager/user_info/update/invaildparams
Response(200,status=101)
{
"status": 101,
"error": "Invaild params."
}