Config - Roles

Object type: role

Request URL: /rest/config/role

Example role Copied

    {
       "object" : {
          "contacts" : [
             {
                "ref" : "/rest/config/contact/1",
                "name" : "admin"
             }
          ],
          "monitoringservers" : [],
          "hostgroups" : [
             {
                "ref" : "/rest/config/hostgroup/1",
                "name" : "Opsview"
             }
          ],
          "name" : "Admin",
          "id" : "10",
          "description" : "Administrator access",
          "accesses" : [
             {
                "ref" : "/rest/config/access/1",
                "name" : "VIEWALL"
             },
             {
                "ref" : "/rest/config/access/14",
                "name" : "PASSWORDSAVE"
             }
          ],
          "access_hostgroups": [],
          "access_servicegroups": [],
          "access_keywords" : [],
          "all_hostgroups" : "0",
          "all_servicegroups" : "0",
          "all_keywords" : "0",
          "all_monitoringservers" : "1",
          "uncommitted" : "0"
       }
    }

If you add a parameter of “order=priority”, this will list the roles in the same order that the web page displays it. Without this parameter, the order is undefined, though usually by id.

Note

The reference to access is not currently available.
["Opsview On-premises"] ["API", "Technical Reference"]

Was this topic helpful?