Retrieving AD Users
From DreamFactory
Line 1: | Line 1: | ||
− | + | === Tutorial === | |
DreamFactory 2.0 Active Directory service allows you to retrieve your Active Directory Users using the 'user' resource. | DreamFactory 2.0 Active Directory service allows you to retrieve your Active Directory Users using the 'user' resource. | ||
This tutorial focuses on retrieving Active Directory Users using an existing DreamFactory Active Directory service. To learn | This tutorial focuses on retrieving Active Directory Users using an existing DreamFactory Active Directory service. To learn | ||
− | how to setup an Active Directory service see [ | + | how to setup an Active Directory service see [[DreamFactory/Tutorials/Using_Active_Directory|Using Active Directory]]. |
− | + | === API Endpoints === | |
* To get a list of all Active Directory Users and their details. | * To get a list of all Active Directory Users and their details. | ||
Line 14: | Line 14: | ||
<pre>GET http://{url}/api/v2/{ad_service}/user/{username}</pre> | <pre>GET http://{url}/api/v2/{ad_service}/user/{username}</pre> | ||
− | + | === Example - Getting list of all Active Directory Users with all fields. === | |
* Service name: ad | * Service name: ad | ||
* Request URL: | * Request URL: | ||
<pre>GET http://foo.com/api/v2/ad/user</pre> | <pre>GET http://foo.com/api/v2/ad/user</pre> | ||
− | + | === Example - Getting list of all Active Directory Users with a specific fields. === | |
* Service name: ad | * Service name: ad | ||
* Fields to retrieve: sn,givenname | * Fields to retrieve: sn,givenname | ||
Line 25: | Line 25: | ||
<pre>GET http://foo.com/api/v2/ad/user?fields=sn,givenname</pre> | <pre>GET http://foo.com/api/v2/ad/user?fields=sn,givenname</pre> | ||
− | + | === Example - Getting a specific User information. === | |
* Service name: ad | * Service name: ad | ||
* Username to retrieve: jdoe | * Username to retrieve: jdoe | ||
Line 31: | Line 31: | ||
<pre>GET http://foo.com/api/v2/ad/user/jdoe</pre> | <pre>GET http://foo.com/api/v2/ad/user/jdoe</pre> | ||
− | + | === Example - Getting a list of users by LDAP query filter. === | |
* Service name: ad | * Service name: ad | ||
* LDAP Query: (sn=Doe) [List users where the sn (last name) is Doe] | * LDAP Query: (sn=Doe) [List users where the sn (last name) is Doe] | ||
* Request URL: | * Request URL: | ||
<pre>GET http://foo.com/api/v2/ad/user?filter=(sn=Doe)</pre> | <pre>GET http://foo.com/api/v2/ad/user?filter=(sn=Doe)</pre> |
Revision as of 18:35, 3 February 2016
Contents
Tutorial
DreamFactory 2.0 Active Directory service allows you to retrieve your Active Directory Users using the 'user' resource.
This tutorial focuses on retrieving Active Directory Users using an existing DreamFactory Active Directory service. To learn how to setup an Active Directory service see Using Active Directory.
API Endpoints
- To get a list of all Active Directory Users and their details.
GET http://{url}/api/v2/{ad_service}/user
- To get details about a specific User.
GET http://{url}/api/v2/{ad_service}/user/{username}
Example - Getting list of all Active Directory Users with all fields.
- Service name: ad
- Request URL:
GET http://foo.com/api/v2/ad/user
Example - Getting list of all Active Directory Users with a specific fields.
- Service name: ad
- Fields to retrieve: sn,givenname
- Request URL:
GET http://foo.com/api/v2/ad/user?fields=sn,givenname
Example - Getting a specific User information.
- Service name: ad
- Username to retrieve: jdoe
- Request URL:
GET http://foo.com/api/v2/ad/user/jdoe
Example - Getting a list of users by LDAP query filter.
- Service name: ad
- LDAP Query: (sn=Doe) [List users where the sn (last name) is Doe]
- Request URL:
GET http://foo.com/api/v2/ad/user?filter=(sn=Doe)