Customer Identity (CIAM)
Register with Email + Verification Code
This interface is called when registering via form with email verification.
# Request Specification
POST https://{your_domain}/api/v2/sdk/register/email-verify-code
# Request Headers
| Parameter Name | Chinese Name | Required | Type | Example |
|---|---|---|---|---|
| X-operating-sys-version | Caller Operating System Version | Yes | String | windows10.1.1 |
| X-device-fingerprint | Caller Device Fingerprint | Yes | String | 156aysdna213sc50 |
| X-device-ip | Caller IP | No | String | 192.168.1.2 |
| X-agent | User-Agent Information | Yes | String | Mozilla/5.0 (iPhone; CPU iPhone OS 13_3 like Mac OS X) |
| X-L | For Internationalization Language Setting | No | String | zh |
| X-client-id | Application Authorization ID | Yes | String | nTo1eRIub60vPb54WeE6aojPwYwImtl4 |
| content-type | Content Format Type | Yes | String | application/json |
# Request Example
{
"user_name": "zhangsan",
"name": "张三",
"mobile": "15200000000",
"email": "15200000000@qq.com",
"verify_code": "1234",
"pwd": "QWE@qwe123",
"head_img": "https://thirdwx.qlogo.cn/mmopen/vi_32/Q0j4TwGTfTIQ8QOTSn3y4cYHLlMC3sv6RCBmeMkxtOog47Zr3v2Afbqc2bmP0WibUIUskX39eJlJ",
"attr_gender": "male",
"attr_birthday": "1992-02-17",
"attr_nick_name": "张三",
"mailing_address": "湖北省武汉市",
"zip_code": "430000",
"first_name": "zhangsan",
"middle_name": "zhangsan",
"last_name": "zhangsan",
"industry": "事业单位",
"extension": {
"age": "18"
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
# Request Parameters
Note: Apart from the mandatory parameters, other parameters need to reference whether the fields are configured as required in the IDaaS user attribute definitions.
| Parameter Name | Chinese Name | Required | Type | Description |
|---|---|---|---|---|
| user_name | Username | No | String | |
| name | Full Name | No | String | |
| mobile | Mobile Number | No | String | |
| Yes | String | |||
| verify_code | Email Verification Code | Yes | String | To obtain the verification code, please refer to the Send Email Verification Code API type=REGISTER_EMS |
| pwd | Password | No | String | |
| head_img | Avatar (URL) | No | String | |
| attr_gender | Gender | No | String | Optional values: female: Female; male: Male; unknow: Confidential |
| attr_birthday | Birthday | No | String | Format: yyyy-MM-dd |
| attr_nick_name | Nickname | No | String | |
| mailing_address | Mailing Address | No | String | |
| zip_code | Postal Code | No | String | |
| first_name | First Name | No | String | |
| middle_name | Middle Name | No | String | |
| last_name | Last Name | No | String | |
| industry | Industry | No | String | |
| extension | Extended Attributes | No | JSONObject | Extended attributes need to be defined within the enterprise |
# Response Example
Success Example:
HTTP/1.1 200 OK
Content-Type: application/json
{
"status": "SUCCESS",
"expire": 43200,
"session_token": "LGTiTNVDFPlpefV3F3Hla7RUFTqInsqa",
"id_token": "eyJ0NiJ9.eyJ1cI6IjIifX0.DeWt4QuZXso"
}
Error Example:
HTTP/1.1 400 Bad Request
{
"error_code": "IDAAS.SDK.USER.0005",
"error_msg": "E-mail cannot be empty"
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# Response Parameters
| Parameter Name | Chinese Name | Type | Description |
|---|---|---|---|
| status | Response Result | String | This field may return the following values: SUCCESS Login successful ACCESS_DENIED Access denied |
| expire | session_token Validity Period | Number | session_token validity period, within which the session_token can be used to obtain a ticket |
| session_token | User session_token | String | User session_token, which can be used to call IDaaS interfaces to obtain an sso_ticket. The sso_ticket can be exchanged for user information |
| id_token | Short-term Valid, Interface Call Token | String | This field is in JWT format and contains user identity information. Refer to Get User Information from id_token to obtain user information. The token validity period defaults to 5 minutes and is configurable |
# Error Codes
| Status Code | Error Code | Error Message | Action |
|---|---|---|---|
| 400 | IDAAS.SDK.PARAM.0001 | Device information is incomplete | Please check if the input device information is complete. |
| Device information is incomplete. | |||
| 400 | IDAAS.SDK.PARAM.0002 | clientId cannot be empty | Please check if the input clientId is empty. |
| clientId cannot be empty. | |||
| 400 | IDAAS.SDK.PARAM.0003 | The app is not registered, please register the app first | Please check if the input clientId is correct. |
| The app is not registered, please register the app first. | |||
| 400 | IDAAS.SDK. PARAM.0009 | Verification code cannot be empty | Please check if the input verification code is empty. |
| Verification code cannot be empty. | |||
| 400 | IDAAS.SDK.USER.0004 | Mobile number cannot be empty | Please check if the input mobile number is empty. |
| Mobile number cannot be empty. | |||
| 400 | IDAAS.SDK.CAPTCHA.0007 | Incorrect verification code | Please check if the input verification code is correct. |
| Incorrect verification code. | |||
| 400 | IDAAS.SDK.USER.0002 | Username cannot be empty | Please check if the username field in the input parameters is empty. |
| Username cannot be empty. | |||
| 400 | IDAAS.SDK.USER.0003 | Name cannot be empty | Please check if the name field in the input parameters is empty. |
| Name cannot be empty. | |||
| 400 | IDAAS.SDK.USER.0005 | E-mail cannot be empty | Please check if the email field in the input parameters is empty. |
| Email cannot be empty. | |||
| 400 | IDAAS.SDK.USER.0007 | Gender cannot be empty | Please check if the gender field in the input parameters is empty. |
| Gender cannot be empty. | |||
| 400 | IDAAS.SDK.USER.0008 | Birthday cannot be empty | Please check if the birthday field in the input parameters is empty. |
| Birthday cannot be empty. | |||
| 400 | IDAAS.SDK.USER.0009 | Nick name cannot be empty | Please check if the nickname field in the input parameters is empty. |
| Nickname cannot be empty. | |||
| 400 | IDAAS.SDK.USER.0010 | Mailing address cannot be empty | Please check if the mailing address field in the input parameters is empty. |
| Mailing address cannot be empty. | |||
| 400 | IDAAS.SDK.USER.0011 | Zip code cannot be empty | Please check if the zip code field in the input parameters is empty. |
| Zip code cannot be empty. | |||
| 400 | IDAAS.SDK.USER.0012 | First name cannot be empty | Please check if the first name field in the input parameters is empty. |
| First name cannot be empty. | |||
| 400 | IDAAS.SDK.USER.0013 | Middle name cannot be empty | Please check if the middle name field in the input parameters is empty. |
| Middle name cannot be empty. | |||
| 400 | IDAAS.SDK.USER.0014 | Last name cannot be empty | Please check if the last name field in the input parameters is empty. |
| Last name cannot be empty. | |||
| 400 | IDAAS.SDK.USER.0015 | Industry cannot be empty | Please check if the industry field in the input parameters is empty. |
| Industry cannot be empty. | |||
| 400 | IDAAS.SDK.USER.0017 | Extended property {0} cannot be empty | Please check if the extended property {0} field in the input parameters is empty. |
| Extended property {0} cannot be empty. | |||
| 400 | IDAAS.SDK.USER.0018 | The username does not meet the verification rules | Please check if the username field in the input parameters complies with the validation rules for the username field defined in [Enterprise Center - Users - User Attribute Definition]. |
| Username does not meet validation rules. | |||
| 400 | IDAAS.SDK.USER.0019 | The name does not meet the verification rules | Please check if the name field in the input parameters complies with the validation rules for the name field defined in [Enterprise Center - Users - User Attribute Definition]. |
| Name does not meet validation rules. | |||
| 400 | IDAAS.SDK.USER.0020 | The phone number does not meet the verification rules | Please check if the phone number field in the input parameters complies with the validation rules for the phone number field defined in [Enterprise Center - Users - User Attribute Definition]. |
| Phone number does not meet validation rules. | |||
| 400 | IDAAS.SDK.USER.0021 | The e-mail does not meet the verification rules | Please check if the email field in the input parameters complies with the validation rules for the email field defined in [Enterprise Center - Users - User Attribute Definition]. |
| Email does not meet validation rules. | |||
| 400 | IDAAS.SDK.USER.0023 | The gender does not meet the verification rules | Please check if the gender field in the input parameters complies with the validation rules for the gender field defined in [Enterprise Center - Users - User Attribute Definition]. |
| Gender does not meet validation rules. | |||
| 400 | IDAAS.SDK.USER.0024 | The birthday does not meet the verification rules | Please check if the birthday field in the input parameters complies with the validation rules for the birthday field defined in [Enterprise Center - Users - User Attribute Definition]. |
| Birthday does not meet validation rules. | |||
| 400 | IDAAS.SDK.USER.0025 | The nickname does not meet the verification rules | Please check if the nickname field in the input parameters complies with the validation rules for the nickname field defined in [Enterprise Center - Users - User Attribute Definition]. |
| Nickname does not meet validation rules. | |||
| 400 | IDAAS.SDK.USER.0026 | The mailing address does not meet the verification rules | Please check if the mailing address field in the input parameters complies with the validation rules for the mailing address field defined in [Enterprise Center - Users - User Attribute Definition]. |
| Mailing address does not meet validation rules. | |||
| 400 | IDAAS.SDK.USER.0027 | The zip code does not meet the verification rules | Please check if the zip code field in the input parameters complies with the validation rules for the birthday field defined in [Enterprise Center - Users - User Attribute Definition]. |
| Zip code does not meet validation rules. | |||
| 400 | IDAAS.SDK.USER.0028 | The first name does not meet the verification rules | Please check if the first name field in the input parameters complies with the validation rules for the first name field defined in [Enterprise Center - Users - User Attribute Definition]. |
| First name does not meet validation rules. | |||
| 400 | IDAAS.SDK.USER.0029 | The middle name does not meet the verification rules | Please check if the middle name field in the input parameters complies with the validation rules for the middle name field defined in [Enterprise Center - Users - User Attribute Definition]. |
| Middle name does not meet validation rules. | |||
| 400 | IDAAS.SDK.USER.0030 | The last name does not meet the verification rules | Please check if the last name field in the input parameters complies with the validation rules for the last name field defined in [Enterprise Center - Users - User Attribute Definition]. |
| Last name does not meet validation rules. | |||
| 400 | IDAAS.SDK.USER.0031 | The industry does not meet the verification rules | Please check if the industry field in the input parameters complies with the validation rules for the industry field defined in [Enterprise Center - Users - User Attribute Definition]. |
| Industry does not meet validation rules. | |||
| 400 | IDAAS.SDK.USER.0033 | The extended attribute {0} does not meet the verification rules | Please check if the extended attribute {0} field in the input parameters complies with the validation rules for the extended attribute {0} field defined in [Enterprise Center - Users - User Attribute Definition]. |
| Extended attribute {0} does not meet validation rules. | |||
| 400 | IDAAS.SDK.MOBILE.0002 | An unauthenticated cell phone number | Please check if the configuration in [Enterprise Center - Enterprise Configuration - International Dialing Code Configuration] complies with the configuration rules. |
| Unauthenticated phone number. | |||
| 400 | IDAAS.SDK.USER.0034 | Username already exists | Please check if the user exists. |
| Username already exists. | |||
| 400 | IDAAS.SDK.USER.0035 | Phone number already exists | Delete the phone number and re-add it, or replace it with a phone number that has not been added before. |
| Phone number already exists. | |||
| 400 | IDAAS.SDK.USER.0036 | Email already exists | Delete the email and re-add it, or replace it with an email that has not been added before. |
| Email already exists. | |||
| 400 | IDAAS.SDK.USER.0037 | Extended property {0} already exists | Delete the extended property {0} and re-add it, or replace it with an extended property {0} that has not been added before. |
| Extended property {0} already exists. |
I understand. I am ready to translate the Markdown documentation for the openplatform. Please paste the content you need translated, and I will follow all the rules you have provided.
