Departments API allows you to get all your departments.
Here's the example response for the Departments API methods:
{
"data": [
{
"id": 233046,
"name": "Support",
"agents": [
{
"id": 6692,
"name": "Borat",
"email": "borat.sagdiyev@example.net",
"role": "admin"
},
{
"id": 6668,
"name": "Ali",
"email": "ali.g@indahouse.com",
"role": "admin"
},
{
"id": 3279,
"name": "Brüno",
"email": "bruno@example.net",
"role": "admin"
}
]
},
{
"id": 142139,
"name": "Marketing",
"agents": [
{
"id": 6668,
"name": "Ali",
"email": "ali.g@indahouse.com",
"role": "admin"
},
{
"id": 6677,
"name": "Benny",
"email": "benny.hill@example.net",
"role": "superviser"
},
{
"id": 4188,
"name": "Mr. Bean",
"email": "bean@example.net",
"role": "admin"
}
]
}
]
}
Below you can find details on each of the Department Object fields.
Field | Type | Description |
id | Integer | Unique id of the department provided by HelpCrunch |
name | String | Department name |
agents | Array of agent objects | Array of Agent Objects |
If you have any questions regarding the REST API, feel free to chat us any time.
👩💻 Happy Coding! 👨💻