REST API - getLdapEntry

The table summarizes the REST API - getLdapEntry.

Request

Format
GET <baseurl>/directory/entry/<ldapalias>/<ldapdn>
Path parameters
  • ldapalias: the alias of the LDAP entry being enquired upon. LDAP connection shared resources are named with the prefix ldap/de/ in order to indicate that they are intended for Directory Engine use. The alias given here is that name without the ldap/de/ prefix. Can be obtained from a previous call to listLdapConnections .
  • ldapdn: the base Distinguished Name (DN) to which the query is restricted. This is relative to, and in addition to, any base DN specified in the LDAP connection shared resource's URL. You can get the required ldapdn from a previous call to one of the listCandidateResources , executeLdapQuery , or getResource operations.
Query parameters attrname=string (optional): the name of the attribute being enquired about. There may be zero or more repetitions of this entry, one per attribute. If no attribute names are included, all the entry’s attributes are returned.

Response

JSON Returns a JSON representation of the content of the getLdapEntryResponse element.
XML Returns the content of the getLdapEntryResponse element (from the DirectoryService schema).

Example

Request
GET <baseurl>/directory/entry/easyAs/ou=Jon%20Parkin,ou=Paris,ou=AllEmployees,o=easyAsInsurance?attr-name=employeetype&attrname=userpassword
Response
 {
       "xml-fragment":
       {
           "@ldap-alias": "easyAs",
           "@ldap-dn": "ou=Jon Parkin,ou=Paris,ou=AllEmployees,o=easyAsInsurance",
           "attribute":
           [
               {
                   "@name": "employeetype",
                   "value": "Permanent"
               },
               {
                   "@name": "userpassword",
                   "@binary": "true",
                   "value": "dGliY28xMjM="
               }
           ]
       }
    }