Importing Users in Batches
Function
This API is used to import users in batches.
Calling Method
For details, see Calling APIs.
Authorization Information
Each account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions.
- If you are using role/policy-based authorization, see Permissions Policies and Supported Actions for details on the required permissions.
- If you are using identity policy-based authorization, no identity policy-based permission required for calling this API.
URI
POST /v1/csms/users/batch-import
Request Parameters
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
X-Auth-Token |
Yes |
String |
User token. It can be obtained by calling the IAM API. The token is the value of X-Subject-Token in the response header. |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
total |
Yes |
Integer |
Number of imported records. |
|
users |
Yes |
Array of CreateUserRequest objects |
User list. |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
user_name |
Yes |
String |
Username, which is a unique identifier in an enterprise. |
|
mobile |
Yes |
String |
Mobile number, which is unique in an enterprise. |
|
password |
No |
String |
Password, which must be in the format defined by the enterprise. |
|
org_code |
No |
String |
Main organization code. Enter an existing organization code in an enterprise. If the value is left empty, the organization is under the first root organization. |
|
name |
No |
String |
Real name. If the value is null, user_name is used. You can modify the mandatory attributes. To do so, log in to the administrator portal, and access the User Attributes page under the Users menu. |
|
|
No |
String |
Email address. You can modify the mandatory attributes. To do so, log in to the administrator portal, and access the User Attributes page under the Users menu. |
|
employee_id |
No |
String |
Employee ID. You can modify the mandatory attributes. To do so, log in to the administrator portal, and access the User Attributes page under the Users menu. |
|
first_name |
No |
String |
Name. You can modify the mandatory attributes. To do so, log in to the administrator portal, and access the User Attributes page under the Users menu. |
|
middle_name |
No |
String |
Middle name. You can modify the mandatory attributes. To do so, log in to the administrator portal, and access the User Attributes page under the Users menu. |
|
last_name |
No |
String |
Last name. You can modify the mandatory attributes. To do so, log in to the administrator portal, and access the User Attributes page under the Users menu. |
|
pwd_must_modify |
No |
Boolean |
Whether the password must be changed upon first login. The default value is true. |
|
attr_gender |
No |
String |
Gender. |
|
attr_birthday |
No |
String |
Date of birth, in yyyy-mm-dd format |
|
attr_nick_name |
No |
String |
Alias. |
|
attr_identity_type |
No |
String |
Certificate type. |
|
attr_identity_number |
No |
String |
Certificate number. |
|
attr_area |
No |
String |
Country or region code. |
|
attr_city |
No |
String |
City. |
|
attr_manager_id |
No |
String |
Immediate superior. |
|
attr_user_type |
No |
String |
Personnel type. The value can be regular (formal), intern (internship), dispatch (labor dispatch), or outsourcing (labor outsourcing). |
|
attr_hire_date |
No |
String |
Onboarding date, in yyyy-MM-dd format. |
|
attr_work_place |
No |
String |
Work location. |
|
user_org_relation_list |
No |
Array of UserOrgRelationListOption objects |
Relationships between users and organizations. The main organization information must be included if this parameter is set. |
|
extension |
No |
Object |
Custom extended attribute. |
Response Parameters
Status code: 200
|
Parameter |
Type |
Description |
|---|---|---|
|
error_list |
Array of ErrorInfo objects |
Failure description. |
|
total |
Integer |
Total number of records. |
|
success |
Integer |
Number of successful records. |
|
failed |
Integer |
Number of failed records. |
Example Requests
None
Example Responses
None
Status Codes
|
Status Code |
Description |
|---|---|
|
200 |
Import status. |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot