List LDAP Users
This API returns the list of users available in the connected LDAP directory server.
Endpoint Details
| URL | /v1/ldap/users |
| Method | GET |
| Authorization | Bearer Token |
Request Headers
| Header | Type | Description |
|---|---|---|
| Content-Type | String | Must 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
| Field | Type | Description |
|---|---|---|
| dn | String | Distinguished name of the user in the LDAP directory |
| sam_account_name | String | SAM account name of the user |
| String | Email address of the user | |
| user_principal_name | String | User principal name (UPN) of the user |
| display_name | String | Display name of the user |
| given_name | String | Given (first) name of the user |
| sn | String | Surname (last name) of the user |
| cn | String | Common 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
snmay not be present when the corresponding attribute is not set in the LDAP directory.