Roles

Use the following API methods to request details about roles.

get_roles

Returns a list of available roles 

 

This endpoint requires TestRail 7.3 or later.

GET index.php?/api/v2/get_roles

Response Content (TestRail Professional)

Please see the following example for a typical response:

{
    "offset": 0,
    "limit": 250,
    "size": 2,
    "_links": {
        "next": null,
        "prev": null
    },
    "roles": [
        {
            "id": 3,
            "name": "Tester",
            "is_default": false
        },
        {
            "id": 1,
            "name": "Lead",
            "is_default": true
        }
    ]
}

Response Content (TestRail Enterprise)

Please see the following example for a typical response:

{
    "offset": 0,
    "limit": 250,
    "size": 2,
    "_links": {
        "next": null,
        "prev": null
    },
    "roles": [
        {
            "id": 3,
            "name": "Tester",
            "is_default": false,
            "is_project_admin": false
        },
        {
            "id": 1,
            "name": "Lead",
            "is_default": true,
            "is_project_admin": false
        }
    ]
}

The following fields are included in the response:

Name Type Description
id integer The ID of the role
name string The name of the role
is_default boolean True if this is the default user role
is_project_admin boolean True if the role has Project Level Administration permissions. (Requires TestRail Enterprise)

Was this article helpful?
0 out of 1 found this helpful