Get list of roles

The Get list of roles method returns the list of manager roles of the current reseller (see Managers' roles).

An API token of a manager is required for authorization. To get an API token via the Operator Control Panel, see Viewing and updating manager's information

The manager's API token specified in an API request determines:

  • The role and access level of the manager, which determine the availability of a method.
  • The current reseller and downstream resellers accessible within a method.

GET {base_url}/api/v3/resellers/{reseller_id}/manager_roles

Arguments

Name

Parameter Type

Data type

Required/ Optional

Description

X-Api-TokenheaderstringRequiredAPI token of a manager that performs the operation (see Viewing and updating manager's information)
Content-TypeheaderstringRequiredMedia type of the request. Specify the following: application/vnd.api+json
AcceptheaderstringRequired

Supported media types of the answer. Specify the following: application/vnd.api+json

base_urlpathstringRequiredActivePlatform URL
reseller_idpathintegerRequiredThe ID of the current reseller only (see Viewing and updating reseller general information)
page[size]queryintegerOptionalPage navigation: number of elements per page. The default value is 50
page[number]queryintegerOptionalPage navigation: page number

Response model

Name

Data type

Description

dataarray of objectsResponse data


id

stringThe ID of a role

typestringData type

attributesobjectInformation about a role


created_at

dateThe date and time of a role creation


updated_at

dateThe date and time when a role was updated


namestringThe role name


reseller_idintegerThe reseller ID
linksobjectPage navigation links that use the defined page navigation parameters

selfstringCurrent page link

firststringFirst page link

prevstringPrevious page link

nextstringNext page link

laststringLast page link

Request example

GET /api/v3/resellers/1/manager_roles
Host: test.activeplatform.com
Content-Type: application/vnd.api+json
X-Api-Token: vY5fwetestK3gJXZH5uHCw
Accept: application/vnd.api+json

Response example

{
    "data": [
        {
            "id": "1",
            "type": "manager_roles",
            "attributes": {
                "created_at": "2023-09-18T13:25:15.066+03:00",
                "updated_at": "2023-09-18T13:25:15.066+03:00",
                "name": "Full control",
                "reseller_id": 1
            }
        },
        {
            "id": "2",
            "type": "manager_roles",
            "attributes": {
                "created_at": "2023-09-18T13:25:38.378+03:00",
                "updated_at": "2023-09-18T13:25:38.378+03:00",
                "name": "Sales",
                "reseller_id": 1
            }
        }
    ],
    "links": {
        "self": "https://test.activeplatform.com/api/v3/resellers/1/manager_roles?page%5Bnumber%5D=1&page%5Bsize%5D=50",
        "first": "https://test.activeplatform.com/api/v3/resellers/1/manager_roles?page%5Bnumber%5D=1&page%5Bsize%5D=50",
        "prev": null,
        "next": null,
        "last": "https://test.activeplatform.com/api/v3/resellers/1/manager_roles?page%5Bnumber%5D=1&page%5Bsize%5D=50"
    }
}