CreateIAM2VirtualIDLdapBinding
API Request
URLs
POST zstack/v1/iam2/ldap/bindings
Headers
Authorization: OAuth the-session-uuid
Curl
Sample
curl -H "Content-Type: application/json;charset=UTF-8" \
-H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \
-X POST http://localhost:8080/zstack/v1/iam2/ldap/bindings
Request Parameters
Name | Type | Location | Description | Optional Value | Starting Version |
---|---|---|---|---|---|
virtualIDUuid | String | body | The user UUID. | 3.5.1 | |
ldapUid | String | body | The AD/LDAP user UUID. | 3.5.1 | |
resourceUuid | String | body | Optional. | 3.5.1 | |
tagUuids | List | body | Optional. The tag UUID list. | 3.5.1 | |
systemTags | List | body | Optional. The system tags. | 3.5.1 | |
userTags | List | body | Optional. The user tags. | 3.5.1 |
API Response
Sample
Response
{
"inventory": {
"uuid": "35f1a7c85cf038f6892a9c6b5e2f0470",
"ldapUid": "ou\u003dEmployee,uid\u003dtest",
"ldapServerUuid": "1bca8f5b607b3d0d9cc5b22270c3a262",
"virtualIDUuid": "5d1be61d0d1d3657afdd9e7829f4d2ed"
}
}
Name | Type | Description | Starting Version |
---|---|---|---|
error | ErrorCode | The error code. If not null, the operation fails, or vice versa. For more information, see error. | 3.5.1 |
inventory | LdapIAM2VirtualIDRefInventory | See inventory. | 3.5.1 |
#error
Name | Type | Description | Starting Version |
---|---|---|---|
code | String | The error code, which is a numbered or alphanumeric code that specifies an error. For example, SYS.1000, HOST.1001. | 3.5.1 |
description | String | The brief description of the error. | 3.5.1 |
details | String | The details about the error. | 3.5.1 |
elaboration | String | The reserved field. Default value: null. | 3.5.1 |
opaque | LinkedHashMap | The reserved field. Default value: null. | 3.5.1 |
cause | ErrorCode | The root error, which is the associated root cause of the current error. If no root error exists, this parameter is null. | 3.5.1 |
#inventory
Name | Type | Description | Starting Version |
---|---|---|---|
uuid | String | The resource UUID. | 3.5.1 |
ldapUid | String | The AD/LDAP entry UID. | 3.5.1 |
ldapServerUuid | String | The AD/LDAP server UUID. | 3.5.1 |
resourceUuid | String | The UUID of the associated resource. | 3.5.1 |
createDate | Timestamp | The creation date. | 3.5.1 |
lastOpDate | Timestamp | The last operation date. | 3.5.1 |
SDK Sample
Java
SDK
CreateIAM2VirtualIDLdapBindingAction action = new CreateIAM2VirtualIDLdapBindingAction();
action.virtualIDUuid = "52d9727518053f50889bebe14617d2d2";
action.ldapUid = "ou=Employee,uid=test";
action.sessionId = "b86c9016b4f24953a9edefb53ca0678c";
CreateIAM2VirtualIDLdapBindingAction.Result res = action.call();
Python
SDK
CreateIAM2VirtualIDLdapBindingAction action = CreateIAM2VirtualIDLdapBindingAction()
action.virtualIDUuid = "52d9727518053f50889bebe14617d2d2"
action.ldapUid = "ou=Employee,uid=test"
action.sessionId = "b86c9016b4f24953a9edefb53ca0678c"
CreateIAM2VirtualIDLdapBindingAction.Result res = action.call()