Skip to main content

List LDAP Users

This API returns the list of users available in the connected LDAP directory server.

Endpoint Details

URL/v1/ldap/users
MethodGET
AuthorizationBearer Token

Request Headers

HeaderTypeDescription
Content-TypeStringMust be application/json

Response

Here is an example of a response when viewing a list of data:

Response
{
"users": [
{
"dn": "CN=member aplikasi,OU=Users,DC=example,DC=com",
"sam_account_name": "member_aplikasi",
"mail": "member.aplikasi@example.com",
"user_principal_name": "member_aplikasi@example.com",
"display_name": "member aplikasi",
"given_name": "member",
"sn": "aplikasi",
"cn": "member aplikasi"
},
{
"dn": "CN=dummy user,OU=Taka,DC=prima,DC=net",
"sam_account_name": "takadump1",
"mail": "rogin30323@newtrea.com",
"user_principal_name": "takadump1@prima.net",
"display_name": "dummy user",
"given_name": "dummy",
"sn": "user",
"cn": "dummy user"
},
{
"dn": "CN=master zilong,OU=Taka,DC=prima,DC=net",
"sam_account_name": "masterzilong",
"mail": "masterzilong31@gmail.com",
"user_principal_name": "masterzilong@prima.net",
"display_name": "master zilong",
"given_name": "master",
"sn": "zilong",
"cn": "master zilong"
},
{
"dn": "CN=john doe,OU=Users,DC=example,DC=com",
"sam_account_name": "johndoe",
"mail": "john.doe@example.com",
"user_principal_name": "johndoe@example.com",
"display_name": "john doe",
"given_name": "john",
"sn": "doe",
"cn": "john doe"
}
]
}

Field Descriptions

FieldTypeDescription
dnStringDistinguished name of the user in the LDAP directory
sam_account_nameStringSAM account name of the user
mailStringEmail address of the user
user_principal_nameStringUser principal name (UPN) of the user
display_nameStringDisplay name of the user
given_nameStringGiven (first) name of the user
snStringSurname (last name) of the user
cnStringCommon name of the user

info
  • A valid Bearer Token is required to access this endpoint.
  • The response reflects the users currently available in the connected LDAP directory server.
  • Some fields such as sn may not be present when the corresponding attribute is not set in the LDAP directory.