Get details of all departments
This API is used to get details of all the departments in an organization.
API: https://meeting.zoho.com/api/v2/{orgId}/department
Method: Get
OAuth Scope: ZohoMeeting.department.READ
Path Params:
orgId - organization id which is retrieved from currentUser api
Params:
index - Page Number. Default value 0.
count - No.Of records.Default value 20.
Request Example:
Copiedhttps://meeting.zoho.com/api/v2/123454/department?index=0&count=1
Response Example:
Copied{
"representation": [
{
"departmentId": "123456789123",
"departmentName": "MEETING",
"source": "MEETING",
"status": 1,
"createdTime": "1685988322741",
"modifiedTime": "1685988322741"
}
],
"resourceType": "/api/v2/1234567/department"
}
POSSIBLE ERROR CASES
1. Invalid DC or Invalid token
HTTP Code: 400
HTTP Body:
Copied{
"error": {
"code": 2000,
"message": "INVALID_OAUTHTOKEN"
}
}
Resolution: Check whether the entered DC is correct and entered token is not expired.
2. Invalid orgId
HTTP Code: 403
HTTP Body:
Copied{
"error": {
"code": 1025,
"message": "Org doesn't matches with request uri"
},
"resourceType": "/meeting/api/v2/1234567/user"
}
Resolution: Check whether the entered organization id is correct.
3. Invalid Org Admin
HTTP Code: 403
HTTP Body:
Copied{
"error": {
"code": 1009,
"message": "Invalid org admin"
},
"resourceType": "/meeting/api/v2/1234567/user"
}
Resolution: Only admin can access this API. Kindly contact the admin.
4. Limit Exceeded
HTTP Code: 400
HTTP Body:
Copied{
"error": {
"code": 1028,
"message": "Count shouldn't exceed 100"
},
"resourceType": "/api/v2/1234567/department"
}
Resolution: Max limit is 100.