You need to enable JavaScript to run this app.
导航
CreateUser - 创建用户
最近更新时间:2025.03.21 11:10:03首次发布时间:2025.03.21 11:10:03
我的收藏
有用
有用
无用
无用

创建用户

请求参数

下表仅列出该接口特有的请求参数和部分公共参数。更多信息请见公共参数

参数
类型
是否必填
示例值
描述
Action
String

CreateUser

要执行的操作,取值:CreateUser。

Version
String

2023-01-01

API的版本,取值:2023-01-01。

UserName
String

username

用户名

DisplayName
String

displayname

显示名

Description
String

description

描述

Email
String

email@email.com

邮箱

Phone
String

1xxxx

联系手机号

返回参数

下表仅列出本接口特有的返回参数。更多信息请参见返回结构

参数
类型
示例值
描述
UserId
String

1

用户id

UserName
String

username

用户名

DisplayName
String

displayname

展示名

Description
String

description

描述

Source
String

Manual 手动创建

来源

CreatedTime
String

2024-07-22T21:53:54+08:00

创建时间

UpdatedTime
String

2024-07-22T21:53:54+08:00

更新时间

Email
String

email@email.com

邮箱

Phone
String

1xxxxx

手机号

请求示例

POST /?Action=CreateUser&Version=2023-01-01 HTTP/1.1
Host: https://open.volcengineapi.com
Content-Type: application/json; charset=UTF-8
X-Date: 20250309T144824Z
X-Content-Sha256: 287e874e******d653b44d21e
Authorization: HMAC-SHA256 Credential=Adfks******wekfwe/20250309/cn-beijing/cloudidentity/request, SignedHeaders=host;x-content-sha256;x-date, Signature=47a7d934ff7b37c03938******cd7b8278a40a1057690c401e92246a0e41085f

{
  "UserName": "用户名",
  "DisplayName": "l9X1",
  "Description": "VyeCfONcHV",
  "Email": "D@UlQTmSmKGt-3D3_DvmCa1-Lzc.AJHVedF.z5huBi.8J-C84iwBb.C2_8LO-T33jj3FmF-kpyRYh3.hfN.ecbMyMkPz-PNPn._DtjWzW.ht3nBC",
  "Phone": "+9627784204919962"
}

返回示例

{
  "ResponseMetadata": {
    "RequestId": "202503092248300211692411694C2DEF",
    "Action": "CreateUser",
    "Version": "2023-01-01",
    "Service": "cloudidentity",
    "Region": "cn-beijing"
  },
  "Result": {
    "UserId": "XK",
    "UserName": "u",
    "DisplayName": "oBl",
    "Description": "ZH0FYHPR8MA",
    "Source": "Manual 手动创建",
    "CreatedTime": "3oD3c",
    "UpdatedTime": "V",
    "Email": "P5",
    "Phone": "yXCo"
  }
}

错误码

下表为您列举了该接口与业务逻辑相关的错误码。公共错误码请参见公共错误码文档。

状态码
错误码
错误信息
说明
400
PermissionError

No permission to perform action[%s] on resource %s

没有接口权限

400
ParamIncludeSensitiveWord

The parameter %v Include sensitive Word

参数 %s 存在敏感词

400
ConcurrentException

Concurrent request exception

存在请求并发冲突

400
ServiceStatusException

Can not perform action[%s] when service is %s

企业身份中心实例不可用

400
InvalidParam

The parameter %v[%v] is invalid

无效参数

404
UserNameAlreadyExists

User name already exists

用户名存在

429
ReachedQuotaLimit

The count of %s is exceeded quota limit

%s 数量达到最大额度

500
InternalError

Unknown internal error: %v

服务内部错误