The following objects are directly related to the role
API.
The role object has the following properties:
Property | Type | Description |
---|---|---|
roleid | ID | ID of the role. Property behavior: - read-only - required for update operations |
name | string | Name of the role. Property behavior: - required for create operations |
type | integer | User type. Possible values: 1 - (default) User; 2 - Admin; 3 - Super admin. Property behavior: - required for create operations |
readonly | integer | Whether the role is readonly. Possible values: 0 - (default) No; 1 - Yes. Property behavior: - read-only |
The role rules object has the following properties:
Property | Type | Description |
---|---|---|
ui | array | Array of the UI element objects. |
ui.default_access | integer | Whether access to new UI elements is enabled. Possible values: 0 - Disabled; 1 - (default) Enabled. |
services.read.mode | integer | Read-only access to services. Possible values: 0 - Read-only access to the services, specified by the services.read.list or matched by the services.read.tag properties;1 - (default) Read-only access to all services. |
services.read.list | array | Array of Service objects. The specified services, including child services, will be granted a read-only access to the user role. Read-only access will not override read-write access to the services. Property behavior: - supported if services.read.mode is set to "0" |
services.read.tag | object | Array of Service tag objects. The tag matched services, including child services, will be granted a read-only access to the user role. Read-only access will not override read-write access to the services. Property behavior: - supported if services.read.mode is set to "0" |
services.write.mode | integer | Read-write access to services. Possible values: 0 - (default) Read-write access to the services, specified by the services.write.list or matched by the services.write.tag properties;1 - Read-write access to all services. |
services.write.list | array | Array of Service objects. The specified services, including child services, will be granted a read-write access to the user role. Read-write access will override read-only access to the services. Property behavior: - supported if services.write.mode is set to "0" |
services.write.tag | object | Array of Service tag objects. The tag matched services, including child services, will be granted a read-write access to the user role. Read-write access will override read-only access to the services. Property behavior: - supported if services.write.mode is set to "0" |
modules | array | Array of the module objects. |
modules.default_access | integer | Whether access to new modules is enabled. Possible values: 0 - Disabled; 1 - (default) Enabled. |
api.access | integer | Whether access to API is enabled. Possible values: 0 - Disabled; 1 - (default) Enabled. |
api.mode | integer | Mode for treating API methods listed in the api property.Possible values: 0 - (default) Deny list; 1 - Allow list. |
api | array | Array of API methods. |
actions | array | Array of the action objects. |
actions.default_access | integer | Whether access to new actions is enabled. Possible values: 0 - Disabled; 1 - (default) Enabled. |
The UI element object has the following properties:
Property | Type | Description |
---|---|---|
name | string | Name of the UI element. Possible values if type of the Role object is set to "User", "Admin", or "Super admin":monitoring.dashboard - Dashboards;monitoring.problems - Monitoring ¡ú Problems;monitoring.hosts - Monitoring ¡ú Hosts;monitoring.latest_data - Monitoring ¡ú Latest data;monitoring.maps - Monitoring ¡ú Maps;services.services - Services ¡ú Services;services.sla_report - Services ¡ú SLA report;inventory.overview - Inventory ¡ú Overview;inventory.hosts - Inventory ¡ú Hosts;reports.availability_report - Reports ¡ú Availability report;reports.top_triggers - Reports ¡ú Triggers top 100.Possible values if type of the Role object is set to "Admin" or "Super admin":monitoring.discovery - Monitoring ¡ú Discovery;services.sla - Services ¡ú SLA;reports.scheduled_reports - Reports ¡ú Scheduled reports;reports.notifications - Reports ¡ú Notifications;configuration.template_groups - Data collection ¡ú Template groups;configuration.host_groups - Data collection ¡ú Host groups;configuration.templates - Data collection ¡ú Templates;configuration.hosts - Data collection ¡ú Hosts;configuration.maintenance - Data collection ¡ú Maintenance;configuration.discovery - Data collection ¡ú Discovery;configuration.trigger_actions - Alerts ¡ú Actions ¡ú Trigger actions;configuration.service_actions - Alerts ¡ú Actions ¡ú Service actions;configuration.discovery_actions - Alerts ¡ú Actions ¡ú Discovery actions;configuration.autoregistration_actions - Alerts ¡ú Actions ¡ú Autoregistration actions;configuration.internal_actions - Alerts ¡ú Actions ¡ú Internal actions.Possible values if type of the Role object is set to "Super admin":reports.system_info - Reports ¡ú System information;reports.audit - Reports ¡ú Audit log;reports.action_log - Reports ¡ú Action log;configuration.event_correlation - Data collection ¡ú Event correlation;administration.media_types - Alerts ¡ú Media types;administration.scripts - Alerts ¡ú Scripts;administration.user_groups - Users ¡ú User groups;administration.user_roles - Users ¡ú User roles;administration.users - Users ¡ú Users;administration.api_tokens - Users ¡ú API tokens;administration.authentication - Users ¡ú Authentication;administration.general - Administration ¡ú General;administration.audit_log - Administration ¡ú Audit log;administration.housekeeping - Administration ¡ú Housekeeping;administration.proxies - Administration ¡ú Proxies;administration.macros - Administration ¡ú Macros;administration.queue - Administration ¡ú Queue.Property behavior: - required |
status | integer | Whether access to the UI element is enabled. Possible values: 0 - Disabled; 1 - (default) Enabled. |
Property | Type | Description |
---|---|---|
serviceid | ID | ID of the Service. Property behavior: - required |
Property | Type | Description |
---|---|---|
tag | string | Tag name. If empty string is specified, the service tag will not be used for service matching. Property behavior: - required |
value | string | Tag value. If no value or empty string is specified, only the tag name will be used for service matching. |
The module object has the following properties:
Property | Type | Description |
---|---|---|
moduleid | ID | ID of the module. Property behavior: - required |
status | integer | Whether access to the module is enabled. Possible values: 0 - Disabled; 1 - (default) Enabled. |
The action object has the following properties:
Property | Type | Description |
---|---|---|
name | string | Name of the action. Possible values if type of the Role object is set to "User", "Admin", or "Super admin:edit_dashboards - Create and edit dashboards;edit_maps - Create and edit maps;add_problem_comments - Add problem comments;change_severity - Change problem severity;acknowledge_problems - Acknowledge problems;suppress_problems - Suppress problems;close_problems - Close problems;execute_scripts - Execute scripts;manage_api_tokens - Manage API tokens.Possible values if type of the Role object is set to "Admin" or "Super admin":edit_maintenance - Create and edit maintenances;manage_scheduled_reports - Manage scheduled reports,manage_sla - Manage SLA.Possible values if type of the Role object is set to "User" or "Admin":invoke_execute_now - allows to execute item checks for users that have only read permissions on host.Property behavior: - required |
status | integer | Whether access to perform the action is enabled. Possible values: 0 - Disabled; 1 - (default) Enabled. |