Adding a User Event
This API is used to synchronize new users to the application system.
URL
POST https://{app_domain}/callback
Request Header
Authorization: Bearer {access_token}
Request Parameters
The following request parameters are subject to the identity synchronization parameters configured by enterprises. The administrator can set which attributes to synchronize with the target application by referring to 9.
Parameter |
Fixed |
Type |
Description |
---|---|---|---|
username |
Yes |
String(100) |
Username. |
name |
Yes |
String(40) |
Real name of the user. |
organizationId |
Yes |
String |
Organization ID. |
password |
Yes |
String |
Password. |
disabled |
Yes |
Boolean |
Whether to disable the function. true: disabled; false: enabled. |
firstName |
No |
String(20) |
Name. |
middleName |
No |
String(20) |
Middle name. |
lastName |
No |
String(20) |
Last name. |
mobile |
No |
String |
Mobile phone number. |
|
No |
String |
Email address. |
extAttr1 |
No |
-- |
Extended attribute 1, which is an extended user attribute of an enterprise. Set this attribute based on the site requirements. |
extAttr2 |
No |
-- |
Extended attribute 2, which is an extended user attribute of an enterprise. Set this attribute based on the site requirements. |
Response Parameters
Parameter |
Type |
Description |
---|---|---|
id |
String(50) |
|
Example Request
- Example request with message signature and encryption enabled:
{ "nonce": "AmgjjEAJbrMzWmUw", "timestamp": 1509384...., "eventType": "CREATE_USER", "data": "6lu6gxrdJIXEWxQhUa3UqsXHWsDZ5LTAo/xU3zhjq9H3syCuFYDYKg==", "signature": "K08yDiTEc094KoccOY+VYLQFxxQ=" }
- The decrypted JSON string in the request body follows this format:
{ "username": "zhangsan", "name": "Tom", "mobile": "1899876....", "email": "zhangsan@test.com", "organizationId": "391551e8-160f-4993-8177-e7b9c5f6....", "extAttr1": "value", "extAttr2": "value" }
Example Response
Status code: 200
Request successful.
- Response example with message signature and encryption enabled:
{ "code": "200", "message": "success", "data": "P+rXpWetRg7IP0vdhVgkVwSoZBJeQwY2zhROsJq/HJ+q6tp1qhl9L1+c" }
- The decrypted JSON string in the response body follows this format:
{ "id": "c3a26dd3-27a0-4dec-a2ac-ce211e10...." }
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