Direct Inward Dialing: +1 408 916 9393
This API enables you to delete any user account from your Active Directory.
Request URL (JSON) format: http://<hostname>:<port>/RestAPI/DeleteUser
Request parameters:
Parameter Name | Mandatory | Description |
PRODUCT_NAME | Yes | Product name / module name from which the request is being sent; will be needed for auditing. |
AuthToken | Yes | Authentication token obtained using the Generate AuthToken API. |
domainName | Yes | Domain name of the user accounts. |
inputFormat | Yes |
Details of each user account to be deleted. This attribute should be a JSONArray string and must be in format mentioned below. [<JSONObject>, <JSONObject>, <JSONObject>]; JSONObject - key/value pair of ldap attributes and the values Sample code in java: JSONArray userDetails = new JSONArray(); JSONObject json = new JSONObject(); json.put("sAMAccountName", "John"); userDetails.put(json); json = new JSONObject(); json.put("sAMAccountName", "Mat"); userDetails.put(json); NOTE: You can specify any of the following attributes as search criteria to locate user objects using REST API requests:
|
Response:
The response will be a JSONArray string which contains the list of JSONObjects. Each JSONObject in the list represents a user account sent in the inputFormat parameter in the request. Each object will contain the following properties.
Parameter Name | Description |
userPrincipalName | userPrincipalName of the user. |
sAMAccountName | sAMAccountName of the user. |
objectSID | objectSID of the user. |
statusMessage | Contains the appropriate message if an issues/error occurs while processing the request. |
Sample Input / Output
Request
http://Byron:8080/RestAPI/DeleteUser?AuthToken=a70d9e6c-4167-4de4-a6a1-3b3aff50c82e&PRODUCT_NAME=MODULE_NAME&domainName=admanagerplus.com&inputFormat=[{"sAMAccountName":"colin.altonen"}]
Response:
[{"userPrincipalName":"colin.altonen@admanagerplus.COM","status":"1","sAMAccountName": "colin.altonen","objectSID":"S-1-5-21-2996321955-1937665885-1535019402-3881","objectGU ID":"{BC22909C-3980-41C6-90E2-EC12685B48F1}","distinguishedName":"CN=colin.altonen, OU=5310 Sanity,DC=admanagerplus,DC=COM","statusMessage":" Successfully deleted the User. "}]
Technician-based delete users limit
The total number of user accounts that technicians can delete in a day using the DeleteUser API depends on the total number of licensed help desk technicians (HDTs).
The maximum number of API calls that an HDT can make is 50/day, irrespective of the tasks that the HDT performs. If you have two HDT licenses, the total number of API calls that you can make is 100/day, that is 2*50.
As the per day API call limit is not task-specific, you can perform any operation but the total number of API calls should not exceed 100. That is, an HDTcan perform a variety of operations like user creation, OU creation, password reset, etc., but the number of API calls for all the tasks put together should not exceed 100.
NOTE:
Reserved characters include ; / ? : @ = &
Unsafe characters include < > # % { } | \ ^ ~ [ ] ` "'