Direct Inward Dialing: +1 408 916 9393
This API enables you to delete any OU from your Active Directory.
Request URL format: http://<hostname>:<port>/RestAPI/DeleteOU
Request parameters:
Parameter name | Mandatory | Description |
PRODUCT_NAME | Yes | Product name or 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 | Name of the domain in which the OUs are present. |
inputFormat | Yes | Details of each OU to be deleted. This attribute should be a JSONArray string and must be in the format mentioned below: [<JSONObject>, <JSONObject>, <JSONObject>];
JSONObject: The key/value pair of LDAP attributes and the values. NOTE: You can specify any of the following attributes as search criteria to locate OU objects using REST API requests: |
Response:
The response will be a JSON array string which contains the list of JSONObjects.
Parameter name | Description |
name | Name of the OU. |
objectGUID | objectGUID of the OU. |
distinguishedName | distinguishedName of the OU. |
ouName | Name of the container from where the OU is deleted. |
statusMessage | Contains the appropriate message if an issue or error occurs while processing the request. |
status | Contains 1 or 0, indicating whether the operation is a success or failure. |
Sample input/output:
Request
http://admanager:8080/RestAPI/DeleteOU?AuthToken=3187f9d3-da6b-4bc2-aaff-a73495753b8d&PRODUCT_NAME=MODULE_NAME&domainName=test.com&inputFormat=[{distinguishedName:,OU=TestUsers,DC=test,DC=com}]
Response:
[ { "name": "TestUsers", "objectGUID": "{9DEF43F1-0A2C-464C-8021-48B32E7B21F6}", "distinguishedName": "OU=TestUsers,DC=test,DC=com", "ouName": "DC=test,DC=com", "statusMessage": "Successfully deleted the OU.", "status": "1" } ]