Employee Identity (EIAM)

Mobile Number + SMS Verification Code Registration Interface

Interface

# Interface Description

This interface is called when using form registration with SMS verification.

# Request Specification

Method URL Type
POST https://{your_domain}/api/v2/sdk/register/mobile-verify-code application/json

# Request Header Parameters

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) AppleWebKit/605.1.15(KHTML, like Gecko)
Mobile/15E148/HuaWei-AnyOffice/2.6.1802.0010/com.huawei.cloudlink.workplace
X-L For Internationalization Language Setting No String zh
X-client-id Application Authorization ID Yes String nTo1eRIub60vPb54WeE6aojPwYwImtl4

# Request Body Example

{
  "user_name": "zhangsan",
  "name": "张三",
  "mobile": "15201657315",
  "verify_code": "1234",
  "email": "15201657315@qq.com",
  "pwd": "QWE@qwe123",
  "head_img": "https://thirdwx.qlogo.cn/mmopen/vi_32/Q0j4TwGTfTIQ8QOTSn3y4cYHLlMC3sv6RCBmeMkxtOog47Zr3v2Afbqc2bmP0WibUIUskX39eJlJ",
  "attr_gender":"male",
  "attr_birthday": "2022-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

# Request Parameters

Parameter Name Chinese Name Required Type Description
user_name Username No String
name Name No String
mobile Mobile Number Yes String
verify_code SMS Verification Code Yes String The received verification code
To get the verification code, please refer to the Send SMS Verification Code API
type = REGISTER_SMS
email Email No String
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 in the Enterprise Center

# Response Example

Success Example:
HTTP/1.1 200 OK
Content-Type: application/json
{
    "status": "SUCCESS",
    "expire": 43200,
    "session_token": "LGTiTNVDFPlpefV3F3Hla7RUFTqInsqa",
    "id_token": "LGTiTNVDFPlpefV3F3Hla7RUFTqInsqa.xsdasd.sdasdas"
}
Error Example:
HTTP/1.1 400 Bad Request
{
    "error_code": "SDK.COMMON.1001",
    "error_msg": "Parameter X-client-id cannot be left blank."
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15

# Response Parameters

Parameter Name Chinese Name Type Description
status Result String Possible return values for this field: SUCCESS Login successful ACCESS_DENIED Access denied
expire session_token Validity Period Number session_token validity period, within which 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 APIs to obtain an sso_ticket. The sso_ticket can be exchanged for user information