POST zstack/v1/ldap/servers
Authorization: OAuth the-session-uuid
{ "params": { "name": "miao", "description": "miao desc", "url": "ldap://localhost:1888", "base": "dc\u003dexample,dc\u003dcom", "username": "", "password": "", "encryption": "None" }, "systemTags": [], "userTags": [] }
curl -H "Content-Type: application/json;charset=UTF-8" \ -H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \ -X POST -d '{"params":{"name":"miao","description":"miao desc","url":"ldap://localhost:1888","base":"dc=example,dc=com","username":"","password":"","encryption":"None"}}' \ http://localhost:8080/zstack/v1/ldap/servers
Name | Type | Location | Description | Optional Value | Starting Version |
---|---|---|---|---|---|
name | String | body (contained in the params structure) | The resource name. | 0.6 | |
description | String | body (contained in the params structure) | The detailed description of the resource. | 0.6 | |
url | String | body (contained in the params structure) | The URL of the LDAP server. | 0.6 | |
base | String | body (contained in the params structure) | The base DN of the LDAP server. | 0.6 | |
username | String | body (contained in the params structure) | The username used to access the LDAP server. | 0.6 | |
password | String | body (contained in the params structure) | The password. | 0.6 | |
encryption | String | body (contained in the params structure) | The encryption method. |
| 0.6 |
systemTags | List | body | Optional. The system tags. | 0.6 | |
userTags | List | body | Optional. The user tags. | 0.6 |
virtualIDSyncConfiguration::{\"rules\":[{\"name\":\"name\",\"attribute\":\"cn\",\"type\":\"SYSTEM\",\"optional\":\"true\"},{\"name\":\"fullname\",\"attribute\":\"cn\",\"type\":\"CUSTOM\",\"optional\":\"true\"}]}
virtualIDSyncConfiguration::{\"rules\":[{\"name\":\"name\",\"attribute\":\"cn\",\"type\":\"SYSTEM\",\"optional\":\"true\"},{\"name\":\"fullname\",\"attribute\":\"cn\",\"type\":\"CUSTOM\",\"optional\":\"true\"}]}
organizationSyncConfiguration::{\"rules\":[{\"name\":\"name\",\"attribute\":\"distinguishedName\",\"type\":\"SYSTEM\",\"optional\":\"true\"},{\"name\":\"description\",\"attribute\":description,\"type\":\"SYSTEM\",\"optional\":\"true\"}],\"strategy\":\"Group\"}
organizationSyncConfiguration::{\"rules\":[{\"name\":\"name\",\"attribute\":\"distinguishedName\",\"type\":\"SYSTEM\",\"optional\":\"true\"},{\"name\":\"description\",\"attribute\":description,\"type\":\"SYSTEM\",\"optional\":\"true\"}],\"strategy\":\"Group\"}
{ "inventory": { "uuid": "ef7291bd94ce478880938851e3ff6ad6", "name": "miao", "description": "miao desc", "url": "ldap://localhost:1888", "base": "dc\u003dexample,dc\u003dcom", "username": "", "password": "", "encryption": "None" } }
Name | Type | Description | Starting Version |
---|---|---|---|
error | ErrorCode | The error code. If not null, the operation fails, or vice versa. For more information, see error. | 0.6 |
inventory | LdapServerInventory | See inventory. | 0.6 |
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. | 0.6 |
description | String | The brief description of the error. | 0.6 |
details | String | The details about the error. | 0.6 |
elaboration | String | The reserved field. Default value: null. | 0.6 |
opaque | LinkedHashMap | The reserved field. Default value: null. | 0.6 |
cause | ErrorCode | The root error, which is the associated root cause of the current error. If no root error exists, this parameter is null. | 0.6 |
Name | Type | Description | Starting Version |
---|---|---|---|
uuid | String | The resource UUID. | 0.6 |
name | String | The resource name. | 0.6 |
description | String | The detailed description of the resource. | 0.6 |
url | String | 0.6 | |
base | String | The base DN of the LDAP server. | 0.6 |
username | String | The username used to access the LDAP server. | 0.6 |
password | String | The password. | 0.6 |
encryption | String | The encryption method. | 0.6 |
createDate | Timestamp | The creation date. | 0.6 |
lastOpDate | Timestamp | The last operation date. | 0.6 |
AddLdapServerAction action = new AddLdapServerAction(); action.name = "miao"; action.description = "miao desc"; action.url = "ldap://localhost:1888"; action.base = "dc=example,dc=com"; action.username = ""; action.password = ""; action.encryption = "None"; action.sessionId = "c805609607b94f1688e4f5791089ab6f"; AddLdapServerAction.Result res = action.call();
AddLdapServerAction action = AddLdapServerAction() action.name = "miao" action.description = "miao desc" action.url = "ldap://localhost:1888" action.base = "dc=example,dc=com" action.username = "" action.password = "" action.encryption = "None" action.sessionId = "611a70f771874450945f77465bca7642" AddLdapServerAction.Result res = action.call()
DELETE/v1/ldap/servers/{uuid}?deleteMode={deleteMode}
Authorization: OAuth the-session-uuid
curl -H "Content-Type: application/json;charset=UTF-8" \ -H "Authorization: OAuth a90abb1116c0428097769adfdc9ae867" \ -X DELETE http://localhost:8080/zstack/v1/ldap/servers/93d7c467c493464fa3d244163c94f64e?deleteMode=Permissive
Name | Type | Location | Description | Optional Value | Starting Version |
---|---|---|---|---|---|
uuid | String | url | The resource UUID. | 0.6 | |
deleteMode | String | body | Optional. The delete mode. | 0.6 | |
systemTags | List | body | Optional. The system tags. | 0.6 | |
userTags | List | body | Optional. The user tags. | 0.6 |
{ "error": { "code": "SYS.1001", "description": "A message or a operation timeout", "details": "Create VM on KVM timeout after 300s" } }
DeleteLdapServerAction action = new DeleteLdapServerAction(); action.uuid = "0e757aebf26346c19ee1f163ea9f0915"; action.deleteMode = "Permissive"; action.sessionId = "3dae39cdbba749ba91deda6b854695ec"; DeleteLdapServerAction.Result res = action.call();
DeleteLdapServerAction action = DeleteLdapServerAction() action.uuid = "7755f302acd44c62833f9d4eb3f7327c" action.deleteMode = "Permissive" action.sessionId = "61e33f5ab13b44ef873ef7fc719d3804" DeleteLdapServerAction.Result res = action.call()
GET zstack/v1/ldap/servers GET zstack/v1/ldap/servers/{uuid}
Authorization: OAuth the-session-uuid
curl -H "Content-Type: application/json;charset=UTF-8" \ -H "Authorization: OAuth 940b9dba281d40b897497a95e8a0e942" \ -X GET http://localhost:8080/zstack/v1/ldap/servers?q=name=ldap server
curl -H "Content-Type: application/json;charset=UTF-8" \ -H "Authorization: OAuth e4e74e66dc074b24b7071b43b12240a2" \ -X GET http://localhost:8080/zstack/v1/ldap/servers/c898d74cdcb94ac4b3b28ac6b7a8f7f5
Queryable Fields
You can check all queryable fields and resource names that can be queried across tables by using zstack-cli, entering QueryLdapServer, and pressing the Tab key.
{ "inventories": [ { "uuid": "91820f68407a441c9ba031ac15fa322d", "name": "miao", "description": "miao desc", "url": "ldap://localhost:1888", "base": "dc\u003dexample,dc\u003dcom", "username": "", "password": "", "encryption": "None" } ] }
Name | Type | Description | Starting Version |
---|---|---|---|
error | ErrorCode | The error code. If not null, the operation fails, or vice versa. For more information, see error. | 0.6 |
inventories | List | See inventories. | 0.6 |
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. | 0.6 |
description | String | The brief description of the error. | 0.6 |
details | String | The details about the error. | 0.6 |
elaboration | String | The reserved field. Default value: null. | 0.6 |
opaque | LinkedHashMap | The reserved field. Default value: null. | 0.6 |
cause | ErrorCode | The root error, which is the associated root cause of the current error. If no root error exists, this parameter is null. | 0.6 |
Name | Type | Description | Starting Version |
---|---|---|---|
uuid | String | The resource UUID. | 0.6 |
name | String | The resource name. | 0.6 |
description | String | The detailed description of the resource. | 0.6 |
url | String | 0.6 | |
base | String | The base DN of the LDAP server. | 0.6 |
username | String | The username used to access the LDAP server. | 0.6 |
password | String | The password. | 0.6 |
encryption | String | The encryption method. | 0.6 |
createDate | Timestamp | The creation date. | 0.6 |
lastOpDate | Timestamp | The last operation date. | 0.6 |
QueryLdapServerAction action = new QueryLdapServerAction(); action.conditions = asList("name=ldap server"); action.sessionId = "a8d28261d5b940c9bdd4712a511bd537"; QueryLdapServerAction.Result res = action.call();
QueryLdapServerAction action = QueryLdapServerAction() action.conditions = ["name=ldap server"] action.sessionId = "aee6bc43a2fb4f1eb6c35e3a064dd464" QueryLdapServerAction.Result res = action.call()
Back to Top
Email Us
contact@zstack.ioEmail Us
contact@zstack.ioEmail Us
contact@zstack.ioThe download link is sent to your email address.
If you don't see it, check your spam folder, subscription folder, or AD folder. After receiving the email, click the URL to download the documentation.Thank you for using ZStack products and services.
Submit successfully.
We'll connect soon.Thank you for using ZStack products and services.