Skip to content

Retrieves employee groups.

Retrieves employee groups

Method get.group_employees
API version
Description Retrieves employee groups.

Available to: Agents and clients

Request parameters

Name Type Required Description
access_token string yes Access token used to authenticate the request.
user_id number no Unique ID of the client user on whose behalf the agent is making the request. Required for agents. To retrieve a list of client users, use "get.customer_users".
limit number no Maximum number of records to return. See the "Paging" section.
offset number no Number of records to skip before returning results. Default: 0. See the "Paging" section.
filter object no Filtering criteria. See the "Filters" section.
fields array no Fields to include in the response. See the "Viewing returned data" section.
sort array no Sorting criteria. See the "Data sorting" section.

Response parameters

Name Type Valid values Filtering Sorting Description
id number yes Unique employee group ID.
name string yes yes Employee group name.
Employees in the group
members array Employees who belong to the group.
employee_id number Unique employee ID.
employee_full_name string Employee's full name.
Employee phone numbers and availability
phone_numbers array yes Employee landline, mobile, and SIP numbers in the group, including availability and dialing priority. Array order determines dialing priority. Calls can be routed to the list through group_phone_number. Use update.group_employees_numbers to change priority or availability.
employee_phone_number string Employee phone number.
employee_phone_number_id number Unique ID of the employee phone number within the group.
employee_full_name string Employee's full name.
employee_id number Unique employee ID.
available boolean Whether the phone number is available in the group.
Group extension settings
group_phone_number string Maximum length: 5 characters yes yes Group extension number.
queue_enabled boolean yes When true, callers wait in a queue until a group phone number becomes available. Default: false.
channels_count number 1 to 199 yes Maximum number of simultaneous calls to the group.

Example request

{
  "jsonrpc":"2.0",
  "id":"number",
  "method":"get.group_employees",
  "params":{
    "access_token":"string",
    "user_id":"number",
    "offset":"number",
    "limit":"number",
    "filter":{
    },
    "sort":[
      {
        "field":"string",
        "order":"string"
      }
    ],
    "fields":[
      "string"
    ]
  }
}

Example response

{
  "jsonrpc":"2.0",
  "id":"number",
  "result":{
    "metadata":{
    },
    "data":[
      {
        "id":"number",
        "name":"string",
        "members":[
          {
            "employee_id":"number",
            "employee_full_name":"string"
          }
        ],
        "phone_numbers":[
          {
            "employee_phone_number":"string",
            "employee_phone_number_id":"number",
            "employee_full_name":"string",
            "employee_id":"number",
            "available":"boolean"
          }
        ],
        "group_phone_number":"string",
        "queue_enabled":"boolean",
        "channels_count":"number"
      }
    ]
  }
}

Possible errors

See the "Errors for get methods" section.