Skip to content

Commit 84aa93a

Browse files
committed
fix member reset info api docs
1 parent 2ef158f commit 84aa93a

4 files changed

Lines changed: 360 additions & 176 deletions

File tree

‎api-reference/openapi.en.json‎

Lines changed: 90 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -17892,12 +17892,12 @@
1789217892
"post": {
1789317893
"operationId": "memberResetInfo",
1789417894
"summary": "Reset member info",
17895-
"description": "Batch-update multiple profile fields of the current member.",
17895+
"description": "Identify a member and reset the specified profile fields.",
1789617896
"tags": [
1789717897
"Platform/Members"
1789817898
],
1789917899
"x-mint": {
17900-
"content": "## Restrictions\n\n| Aspect | Value |\n| ------ | ----- |\n| Rate limits | **1,000 requests/minute**; **50 requests/second** per account |\n| Permissions | None — any valid `app_key` can call this operation |",
17900+
"content": "## Restrictions\n\n| Aspect | Value |\n| ------ | ----- |\n| Rate limits | **300 requests/minute**; **20 requests/second** per account |\n| Permissions | None — any valid `app_key` can call this operation |\n\n## Usage\n\n- Identify the member with one of `member_id`, `member_name`, `email`, `phone`, or `ref_id`. If multiple identifiers are present, the server checks them in that order.\n- When identifying or updating a member by `phone`, include `country_code` when the number needs country-specific parsing.\n- Put the profile fields to write under `updates`: `member_name`, `password`, `phone`, `country_code`, `email`, `avatar`, `locale`, `time_zone`, or `ref_id`.\n- Members provisioned by SSO cannot be changed when SSO marks them as externally managed.",
1790117901
"href": "/en/api-reference/platform/members/member-reset-info",
1790217902
"metadata": {
1790317903
"sidebarTitle": "Reset member info"
@@ -17952,9 +17952,11 @@
1795217952
},
1795317953
"example": {
1795417954
"member_id": 2476444212131,
17955-
"member_name": "Alice",
17956-
"locale": "zh-CN",
17957-
"time_zone": "Asia/Shanghai"
17955+
"updates": {
17956+
"member_name": "Alice Chen",
17957+
"locale": "zh-CN",
17958+
"time_zone": "Asia/Shanghai"
17959+
}
1795817960
}
1795917961
}
1796017962
}
@@ -42643,70 +42645,114 @@
4264342645
},
4264442646
"MemberResetInfoRequest": {
4264542647
"type": "object",
42646-
"description": "Reset member info request",
42648+
"description": "Reset member info request. Top-level fields identify the member, and updates contains the profile fields to write.",
4264742649
"required": [
42648-
"member_id"
42650+
"updates"
42651+
],
42652+
"anyOf": [
42653+
{
42654+
"required": [
42655+
"member_id"
42656+
]
42657+
},
42658+
{
42659+
"required": [
42660+
"member_name"
42661+
]
42662+
},
42663+
{
42664+
"required": [
42665+
"email"
42666+
]
42667+
},
42668+
{
42669+
"required": [
42670+
"phone"
42671+
]
42672+
},
42673+
{
42674+
"required": [
42675+
"ref_id"
42676+
]
42677+
}
4264942678
],
4265042679
"properties": {
4265142680
"member_id": {
4265242681
"type": "integer",
4265342682
"format": "uint64",
42654-
"description": "Member ID of the member to update"
42683+
"description": "Member ID used to identify the member."
4265542684
},
4265642685
"member_name": {
42657-
"type": [
42658-
"string",
42659-
"null"
42660-
],
42686+
"type": "string",
42687+
"description": "Member name used to identify the member."
42688+
},
42689+
"email": {
42690+
"type": "string",
42691+
"description": "Email address used to identify the member."
42692+
},
42693+
"phone": {
42694+
"type": "string",
42695+
"description": "Phone number used to identify the member. Include country_code when the number is not in E.164 format."
42696+
},
42697+
"country_code": {
42698+
"type": "string",
42699+
"description": "Country or region code used to parse phone."
42700+
},
42701+
"ref_id": {
42702+
"type": "string",
42703+
"description": "External reference ID used to identify the member."
42704+
},
42705+
"updates": {
42706+
"$ref": "#/components/schemas/MemberResetInfoUpdates"
42707+
}
42708+
}
42709+
},
42710+
"MemberResetInfoUpdates": {
42711+
"type": "object",
42712+
"description": "Member profile fields to write. Omitted fields remain unchanged.",
42713+
"properties": {
42714+
"member_name": {
42715+
"type": "string",
4266142716
"minLength": 2,
4266242717
"maxLength": 39,
42663-
"description": "Display name"
42718+
"description": "New display name."
4266442719
},
42665-
"email": {
42666-
"type": [
42667-
"string",
42668-
"null"
42669-
],
42670-
"description": "Email address"
42720+
"password": {
42721+
"type": "string",
42722+
"description": "New login password in the encrypted format accepted by the backend."
4267142723
},
4267242724
"phone": {
42673-
"type": [
42674-
"string",
42675-
"null"
42676-
],
42677-
"description": "Phone number"
42725+
"type": "string",
42726+
"description": "New phone number. Include country_code when the number is not in E.164 format."
4267842727
},
4267942728
"country_code": {
42680-
"type": [
42681-
"string",
42682-
"null"
42683-
],
42684-
"description": "Country code"
42729+
"type": "string",
42730+
"description": "Country or region code for the new phone number."
42731+
},
42732+
"email": {
42733+
"type": "string",
42734+
"description": "New email address."
4268542735
},
4268642736
"avatar": {
42687-
"type": [
42688-
"string",
42689-
"null"
42690-
],
42691-
"description": "Avatar URL"
42737+
"type": "string",
42738+
"maxLength": 499,
42739+
"description": "New avatar URL."
4269242740
},
4269342741
"locale": {
42694-
"type": [
42695-
"string",
42696-
"null"
42697-
],
42742+
"type": "string",
4269842743
"enum": [
4269942744
"zh-CN",
4270042745
"en-US"
4270142746
],
42702-
"description": "Locale"
42747+
"description": "New locale preference."
4270342748
},
4270442749
"time_zone": {
42705-
"type": [
42706-
"string",
42707-
"null"
42708-
],
42709-
"description": "Time zone"
42750+
"type": "string",
42751+
"description": "New IANA time zone name, such as Asia/Shanghai."
42752+
},
42753+
"ref_id": {
42754+
"type": "string",
42755+
"description": "New external reference ID."
4271042756
}
4271142757
}
4271242758
},

‎api-reference/openapi.zh.json‎

Lines changed: 90 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -17884,12 +17884,12 @@
1788417884
"post": {
1788517885
"operationId": "memberResetInfo",
1788617886
"summary": "重置成员信息",
17887-
"description": "批量更新当前成员的多个资料字段。",
17887+
"description": "通过成员标识定位成员,并重置指定资料字段。",
1788817888
"tags": [
1788917889
"平台/成员管理"
1789017890
],
1789117891
"x-mint": {
17892-
"content": "## 限制说明\n\n| 项目 | 说明 |\n| ---- | ---- |\n| 速率限制 | 每个账户 **1,000 次/分钟**;**50 次/秒** |\n| 权限要求 | 无 —— 持有有效的 `app_key` 即可调用 |",
17892+
"content": "## 限制说明\n\n| 项目 | 说明 |\n| ---- | ---- |\n| 速率限制 | 每个账户 **300 次/分钟**;**20 次/秒** |\n| 权限要求 | 无 —— 持有有效的 `app_key` 即可调用 |\n\n## 使用说明\n\n- 使用 `member_id`、`member_name`、`email`、`phone` 或 `ref_id` 中任一字段定位成员;如果同时传多个字段,服务端按上述顺序匹配。\n- 使用 `phone` 定位或更新手机号时,可同时传 `country_code` 辅助解析。\n- `updates` 承载要写入的新资料,支持 `member_name`、`password`、`phone`、`country_code`、`email`、`avatar`、`locale`、`time_zone`、`ref_id`。\n- 由 SSO 托管且不可编辑的成员不能通过此接口修改。",
1789317893
"href": "/zh/api-reference/platform/members/member-reset-info",
1789417894
"metadata": {
1789517895
"sidebarTitle": "重置成员信息"
@@ -17944,9 +17944,11 @@
1794417944
},
1794517945
"example": {
1794617946
"member_id": 2476444212131,
17947-
"member_name": "Alice",
17948-
"locale": "zh-CN",
17949-
"time_zone": "Asia/Shanghai"
17947+
"updates": {
17948+
"member_name": "Alice Chen",
17949+
"locale": "zh-CN",
17950+
"time_zone": "Asia/Shanghai"
17951+
}
1795017952
}
1795117953
}
1795217954
}
@@ -42634,70 +42636,114 @@
4263442636
},
4263542637
"MemberResetInfoRequest": {
4263642638
"type": "object",
42637-
"description": "重置成员信息请求",
42639+
"description": "重置成员信息请求。外层字段用于定位成员,updates 用于传入要写入的新资料。",
4263842640
"required": [
42639-
"member_id"
42641+
"updates"
42642+
],
42643+
"anyOf": [
42644+
{
42645+
"required": [
42646+
"member_id"
42647+
]
42648+
},
42649+
{
42650+
"required": [
42651+
"member_name"
42652+
]
42653+
},
42654+
{
42655+
"required": [
42656+
"email"
42657+
]
42658+
},
42659+
{
42660+
"required": [
42661+
"phone"
42662+
]
42663+
},
42664+
{
42665+
"required": [
42666+
"ref_id"
42667+
]
42668+
}
4264042669
],
4264142670
"properties": {
4264242671
"member_id": {
4264342672
"type": "integer",
4264442673
"format": "uint64",
42645-
"description": "要更新的成员 ID"
42674+
"description": "用于定位成员的成员 ID。"
4264642675
},
4264742676
"member_name": {
42648-
"type": [
42649-
"string",
42650-
"null"
42651-
],
42677+
"type": "string",
42678+
"description": "用于定位成员的成员名称。"
42679+
},
42680+
"email": {
42681+
"type": "string",
42682+
"description": "用于定位成员的邮箱地址。"
42683+
},
42684+
"phone": {
42685+
"type": "string",
42686+
"description": "用于定位成员的手机号;如不是 E.164 格式,可同时传 country_code。"
42687+
},
42688+
"country_code": {
42689+
"type": "string",
42690+
"description": "手机号对应的国家或地区区号,用于解析 phone。"
42691+
},
42692+
"ref_id": {
42693+
"type": "string",
42694+
"description": "用于定位成员的外部引用 ID。"
42695+
},
42696+
"updates": {
42697+
"$ref": "#/components/schemas/MemberResetInfoUpdates"
42698+
}
42699+
}
42700+
},
42701+
"MemberResetInfoUpdates": {
42702+
"type": "object",
42703+
"description": "要写入的成员资料字段。未传的字段保持不变。",
42704+
"properties": {
42705+
"member_name": {
42706+
"type": "string",
4265242707
"minLength": 2,
4265342708
"maxLength": 39,
42654-
"description": "显示名称"
42709+
"description": "新的显示名称。"
4265542710
},
42656-
"email": {
42657-
"type": [
42658-
"string",
42659-
"null"
42660-
],
42661-
"description": "邮箱地址"
42711+
"password": {
42712+
"type": "string",
42713+
"description": "按前端加密格式传入的新登录密码。"
4266242714
},
4266342715
"phone": {
42664-
"type": [
42665-
"string",
42666-
"null"
42667-
],
42668-
"description": "手机号"
42716+
"type": "string",
42717+
"description": "新的手机号;如不是 E.164 格式,可同时传 country_code。"
4266942718
},
4267042719
"country_code": {
42671-
"type": [
42672-
"string",
42673-
"null"
42674-
],
42675-
"description": "国家区号"
42720+
"type": "string",
42721+
"description": "新手机号对应的国家或地区区号。"
42722+
},
42723+
"email": {
42724+
"type": "string",
42725+
"description": "新的邮箱地址。"
4267642726
},
4267742727
"avatar": {
42678-
"type": [
42679-
"string",
42680-
"null"
42681-
],
42682-
"description": "头像 URL"
42728+
"type": "string",
42729+
"maxLength": 499,
42730+
"description": "新的头像 URL。"
4268342731
},
4268442732
"locale": {
42685-
"type": [
42686-
"string",
42687-
"null"
42688-
],
42733+
"type": "string",
4268942734
"enum": [
4269042735
"zh-CN",
4269142736
"en-US"
4269242737
],
42693-
"description": "语言"
42738+
"description": "新的语言偏好。"
4269442739
},
4269542740
"time_zone": {
42696-
"type": [
42697-
"string",
42698-
"null"
42699-
],
42700-
"description": "时区"
42741+
"type": "string",
42742+
"description": "新的 IANA 时区名称,例如 Asia/Shanghai。"
42743+
},
42744+
"ref_id": {
42745+
"type": "string",
42746+
"description": "新的外部引用 ID。"
4270142747
}
4270242748
}
4270342749
},

0 commit comments

Comments
 (0)