Get Designations
Table of Contents
Overview
The zoho.directory.getDesignations task is used to fetch all designations from the specified organization.
Syntax
<response> = zoho.directory.getDesignations(<orgID>, <page>, <perPage>, <connectionName>);
Scope
ZohoDirectory.Orgs.READ where:
| Parameter | Description | Data type |
| response | is the variable which will hold the details of the designations fetched from the organization. | KEY-VALUE |
| <orgID> | is the ID of the organization from which the designations need to be fetched. | NUMBER |
| <connectionName> | is the name of the Zoho Directory connection. | TEXT |
| <page> | To get the list of records based on pages. | NUMBER |
| <per_page> | Maximum number of records (1-200) in a single page. | NUMBER |
Example
The following script fetches the designations of the first 200 users from Zoho Directory organization:
response = zoho.directory.getDesignations(72XXXXXXX, "1", "200", "zoho_directory_connection");
where:
responseThis is the KEY-VALUEresponse returned by Zoho Directory.
72XXXXXXXThis is the NUMBERthat represents the organization ID of Zoho Directory account from which the designation of the users needs to be fetched.
zoho_directory_connectionThis is the TEXTthat represents the link name of the connection.
1This is the NUMBERresponse returned by Zoho Directory.
200This is the NUMBERthat represents the total number of records that need to be fetched.
Response Format
{
"status_code": 200,
"designations": [
{
"created_time": 17**********,
"designation_name": "M*****",
"designation_id": "96********"
},
{
"created_time": 16**********,
"designation_name": "S******",
"designation_id": "71*******"
},..
],
"has_more": false,
"resource_name": "designations"
}