Operations (sample payloads)
Main operationsCopy
Copy
AddCopy
Copy
Perform an LDAP add operation.
Sample Input
1{2"username": "admin",3"password": "secretpassword",4"base_dn": "dc=example,dc=com",5"host": {6"url": "ldap://ldap.example.com",7"port": 3898},9"dn": "cn=John Doe,ou=Users",10"append_base_dn": true,11"entry": {12"objectClass": [13"inetOrgPerson",14"organizationalPerson",15"person"16],17"cn": "John Doe",18"sn": "Doe",19"givenName": "John",20"mail": "john.doe@example.com",21"userPassword": "initialPassword123"22}23}
Sample Output
1{2"success": true3}
Batch get by DNsCopy
Copy
Get a batch of objects from a list of DNs.
Sample Input
1{2"username": "admin",3"password": "secretpassword",4"base_dn": "dc=example,dc=com",5"host": {6"url": "ldap://ldap.example.com",7"port": 3898},9"dns": [10"cn=John Doe,ou=Users,dc=example,dc=com",11"cn=Jane Smith,ou=Users,dc=example,dc=com"12],13"attributes": [14"cn",15"sn",16"givenName",17"mail",18"userPrincipalName"19]20}
Sample Output
1{2"results": [3{4"dn": "cn=John Doe,ou=Users,dc=example,dc=com",5"controls": [],6"objectClass": [7"top",8"person",9"organizationalPerson",10"user"11],12"cn": "John Doe",13"sn": "Doe",14"givenName": "John",15"distinguishedName": "cn=John Doe,ou=Users,dc=example,dc=com",16"instanceType": "4",17"whenCreated": "20230101000000.0Z",18"whenChanged": "20230615120000.0Z",19"displayName": "John Doe",20"uSNCreated": "12345",21"memberOf": "cn=Sales,ou=Groups,dc=example,dc=com",22"uSNChanged": "67890",23"name": "John Doe",24"objectGUID": "f7e5a912-8b3c-4f20-a65d-3a3b7e567890",25"userAccountControl": "512",26"badPwdCount": "0",27"codePage": "0",28"countryCode": "0",29"badPasswordTime": "0",30"lastLogoff": "0",31"lastLogon": "132951234567890000",32"pwdLastSet": "132950000000000000",33"primaryGroupID": "513",34"objectSid": "S-1-5-21-3623811015-3361044348-30300820-1013",35"accountExpires": "9223372036854775807",36"logonCount": "42",37"sAMAccountName": "jdoe",38"sAMAccountType": "805306368",39"userPrincipalName": "jdoe@example.com",40"objectCategory": "cn=Person,cn=Schema,cn=Configuration,dc=example,dc=com",41"dSCorePropagationData": [42"16010101000000.0Z"43],44"mail": "john.doe@example.com"45},46{47"dn": "cn=Jane Smith,ou=Users,dc=example,dc=com",48"controls": [],49"objectClass": [50"top",51"person",52"organizationalPerson",53"user"54],55"cn": "Jane Smith",56"sn": "Smith",57"givenName": "Jane",58"distinguishedName": "cn=Jane Smith,ou=Users,dc=example,dc=com",59"instanceType": "4",60"whenCreated": "20230201000000.0Z",61"whenChanged": "20230614150000.0Z",62"displayName": "Jane Smith",63"uSNCreated": "23456",64"memberOf": "cn=Marketing,ou=Groups,dc=example,dc=com",65"uSNChanged": "78901",66"name": "Jane Smith",67"objectGUID": "a1b2c3d4-5e6f-7g8h-9i0j-1k2l3m4n5o6p",68"userAccountControl": "512",69"badPwdCount": "0",70"codePage": "0",71"countryCode": "0",72"badPasswordTime": "0",73"lastLogoff": "0",74"lastLogon": "132952345678901000",75"pwdLastSet": "132951000000000000",76"primaryGroupID": "513",77"objectSid": "S-1-5-21-3623811015-3361044348-30300820-1014",78"accountExpires": "9223372036854775807",79"logonCount": "37",80"sAMAccountName": "jsmith",81"sAMAccountType": "805306368",82"userPrincipalName": "jsmith@example.com",83"objectCategory": "cn=Person,cn=Schema,cn=Configuration,dc=example,dc=com",84"dSCorePropagationData": [85"16010101000000.0Z"86],87"mail": "jane.smith@example.com"88}89]90}
DeleteCopy
Copy
Perform an LDAP delete operation.
Sample Input
1{2"username": "admin",3"password": "secretpassword",4"base_dn": "dc=example,dc=com",5"host": {6"url": "ldap://ldap.example.com",7"port": 3898},9"dn": "cn=John Doe,ou=Users",10"append_base_dn": true11}
Sample Output
1{2"success": true3}
ModifyCopy
Copy
Perform an LDAP modify operation.
Sample Input
1{2"username": "admin",3"password": "secretpassword",4"base_dn": "dc=example,dc=com",5"host": {6"url": "ldap://ldap.example.com",7"port": 3898},9"dn": "cn=John Doe,ou=Users",10"append_base_dn": true,11"modify_type": "replace",12"entry": {13"mail": "johndoe@example.com",14"telephoneNumber": "+1-555-123-4567"15}16}
Sample Output
1{2"success": true3}
Modify DNCopy
Copy
Modify the DN of an entry.
Sample Input
1{2"username": "admin",3"password": "secretpassword",4"base_dn": "dc=example,dc=com",5"host": {6"url": "ldap://ldap.example.com",7"port": 3898},9"dn": {10"dn": "cn=John Doe,ou=Users",11"append_base_dn": true12},13"new_dn": {14"dn": "cn=John Doe,ou=Employees",15"append_base_dn": true16}17}
Sample Output
1{2"success": true3}
SearchCopy
Copy
Perform an LDAP search operation.
Sample Input
1{2"username": "admin",3"password": "secretpassword",4"base_dn": "dc=example,dc=com",5"host": {6"url": "ldap://ldap.example.com",7"port": 3898},9"append_base_dn": true,10"initial_filter": {11"field": "objectClass",12"condition": "Equals",13"value": "person"14},15"further_filters": [16{17"field": "sn",18"condition": "Equals",19"value": "Smith"20}21],22"conjunction": "&",23"scope": "sub",24"return_type": [25"cn",26"mail",27"telephoneNumber"28],29"return_as_file": false30}
Sample Output
1{2"results": [3{4"dn": "cn=John Smith,ou=People,dc=example,dc=com",5"controls": [],6"cn": "John Smith",7"mail": "john.smith@example.com",8"telephoneNumber": "+1 555-123-4567"9},10{11"dn": "cn=Jane Smith,ou=People,dc=example,dc=com",12"controls": [],13"cn": "Jane Smith",14"mail": "jane.smith@example.com",15"telephoneNumber": "+1 555-987-6543"16}17],18"count": 2,19"total": 220}
Search RawCopy
Copy
Perform an LDAP search operation
Sample Input
1{2"username": "ldap_user",3"password": "password123",4"base_dn": "dc=example,dc=com",5"host": {6"url": "ldap://ldap.example.com",7"port": 3898},9"append_base_dn": true,10"filter": "(objectClass=person)",11"scope": "sub",12"return_type": [13"cn",14"mail",15"givenName",16"sn"17],18"return_as_file": false19}
Sample Output
1{2"results": [3{4"dn": "cn=John Doe,ou=Users,dc=example,dc=com",5"controls": [],6"givenName": "John",7"cn": "John Doe",8"mail": "john.doe@example.com",9"sn": "Doe"10},11{12"dn": "cn=Jane Smith,ou=Users,dc=example,dc=com",13"controls": [],14"givenName": "Jane",15"cn": "Jane Smith",16"mail": "jane.smith@example.com",17"sn": "Smith"18}19],20"count": 2,21"total": 222}