更新个人资料
POST
/web/v1/system/profile/update JWT更新已认证用户自身的个人资料信息。所有字段均为可选,仅非空字段被应用。
鉴权
Auth Chain: WEB Chain — 需要
Authorization: Bearer <jwt>以下请求头由系统自动注入(前端无需处理):X-PORTAL-ACCESS-CODE(Nginx),X-Request-Id(Gateway)
请求参数
请求体
ProfileUpdateRequest:
| Name | Type | Required | In | Description |
|---|---|---|---|---|
accountName | string | Optional | body | 账户显示名称(最多 126 个字符) |
accountPhone | string | Optional | body | 账户手机号(最多 25 个字符) |
defaultLanguage | string | Optional | body | 偏好语言代码(最多 10 个字符,如 "en"、"zh") |
defaultTimezone | string | Optional | body | 偏好时区(最多 50 个字符,如 "America/New_York") |
defaultCountry | string | Optional | body | 偏好国家代码(最多 10 个字符,如 "US") |
请求体示例:
请求体 200
{
"accountName": "Jane Admin",
"accountPhone": "+1987654321",
"defaultLanguage": "zh",
"defaultTimezone": "Asia/Shanghai",
"defaultCountry": "CN"
}请求示例
json
{
"accountName": "John Doe",
"accountPhone": "+1234567890",
"defaultLanguage": "en",
"defaultTimezone": "UTC",
"defaultCountry": "US"
}成功响应
成功 200
{
"success": true,
"code": "2000",
"message": "SUCCESS",
"data": {
"bizId": "ACC_SYS_001",
"institutionBizId": "INST_SYS_001",
"accountEmail": "admin@example.com",
"accountPhone": "+1987654321",
"accountName": "Jane Admin",
"accountRemark": null,
"accountPortal": {
"code": "SYSTEM",
"value": 10010101,
"label": "系统"
},
"accountStatus": {
"code": "ACTIVE",
"value": 10010202,
"label": "活跃"
},
"createdAt": "2026-01-15T08:00:00Z",
"updatedAt": "2026-03-23T10:00:00Z",
"defaultLanguage": "zh",
"defaultTimezone": "Asia/Shanghai",
"defaultCountry": "CN"
}
}错误响应
未授权 401
{
"success": false,
"code": "4010",
"message": "Invalid or expired token"
}| 错误码 | 描述 |
|---|---|
4000 | 验证错误(字段超出最大长度) |
4010 | 未授权(无效或缺少 JWT token) |
说明
- 仅已认证用户可以更新自己的个人资料。
- 所有字段均为可选。仅非空字段被更新。
accountRemark为管理员专用字段,不可通过此接口修改。- 更改即时生效。响应返回完整的更新后资料。