This is the documentation page for an unsupported version of Zabbix.
Is this not what you were looking for? Switch to the current version or choose one from the drop-down menu.

2 Templates

Overview

Templates are exported with many related objects and object relations.

Template export contains:

  • linked host groups
  • template data
  • linkage to other templates
  • linkage to host groups
  • directly linked applications
  • directly linked items
  • directly linked triggers
  • directly linked graphs
  • directly linked screens
  • directly linked discovery rules with all prototypes
  • directly linked web scenarios
  • value maps

Exporting

To export templates, do the following:

  • Go to: ConfigurationTemplates
  • Mark the checkboxes of the templates to export
  • Click on Export below the list

Selected templates are exported to a local XML file with default name zabbix_export_templates.xml.

Importing

To import templates, do the following:

  • Go to: ConfigurationTemplates
  • Click on Import to the right
  • Select the import file
  • Mark the required options in import rules
  • Click on Import

Note that before Zabbix 4.4.4, when a template is imported and updated, it can only be linked to additional templates and never be unlinked from any.

A success or failure message of the import will be displayed in the frontend.

Import rules:

Rule Description
Update existing Existing elements will be updated with data taken from the import file. Otherwise they will not be updated.
Create new The import will add new elements using data from the import file. Otherwise it will not add them.
Delete missing The import will remove existing elements not present in the import file. Otherwise it will not remove them.
If Delete missing is marked for template linkage (only available since 4.4.4), existing template linkage not present in the import file will be removed from the template along with all entities inherited from the potentially unlinked templates (items, triggers, etc).

Export format

<?xml version="1.0" encoding="UTF-8"?>
       <zabbix_export>
           <version>4.4</version>
           <date>2019-10-22T10:03:11Z</date>
           <groups>
               <group>
                   <name>Templates/Modules</name>
               </group>
           </groups>
           <templates>
               <template>
                   <template>Template Module Linux filesystems by Zabbix agent</template>
                   <name>Template Module Linux filesystems by Zabbix agent</name>
                   <description>Template tooling version used: 0.30</description>
                   <groups>
                       <group>
                           <name>Templates/Modules</name>
                       </group>
                   </groups>
                   <applications>
                       <application>
                           <name>Filesystems</name>
                       </application>
                   </applications>
                   <discovery_rules>
                       <discovery_rule>
                           <name>Mounted filesystem discovery</name>
                           <key>vfs.fs.discovery</key>
                           <delay>1h</delay>
                           <filter>
                               <evaltype>AND</evaltype>
                               <conditions>
                                   <condition>
                                       <macro>{#FSTYPE}</macro>
                                       <value>{$VFS.FS.FSTYPE.MATCHES}</value>
                                       <formulaid>C</formulaid>
                                   </condition>
                                   <condition>
                                       <macro>{#FSTYPE}</macro>
                                       <value>{$VFS.FS.FSTYPE.NOT_MATCHES}</value>
                                       <operator>NOT_MATCHES_REGEX</operator>
                                       <formulaid>D</formulaid>
                                   </condition>
                                   <condition>
                                       <macro>{#FSNAME}</macro>
                                       <value>{$VFS.FS.FSNAME.MATCHES}</value>
                                       <formulaid>A</formulaid>
                                   </condition>
                                   <condition>
                                       <macro>{#FSNAME}</macro>
                                       <value>{$VFS.FS.FSNAME.NOT_MATCHES}</value>
                                       <operator>NOT_MATCHES_REGEX</operator>
                                       <formulaid>B</formulaid>
                                   </condition>
                               </conditions>
                           </filter>
                           <description>Discovery of file systems of different types.</description>
                           <item_prototypes>
                               <item_prototype>
                                   <name>{#FSNAME}: Free inodes in %</name>
                                   <key>vfs.fs.inode[{#FSNAME},pfree]</key>
                                   <history>7d</history>
                                   <value_type>FLOAT</value_type>
                                   <units>%</units>
                                   <application_prototypes>
                                       <application_prototype>
                                           <name>Filesystem {#FSNAME}</name>
                                       </application_prototype>
                                   </application_prototypes>
                                   <trigger_prototypes>
                                       <trigger_prototype>
                                           <expression>{min(5m)}<{$VFS.FS.INODE.PFREE.MIN.CRIT:"{#FSNAME}"}</expression>
                                           <name>{#FSNAME}: Running out of free inodes (free < {$VFS.FS.INODE.PFREE.MIN.CRIT:"{#FSNAME}"}%)</name>
                                           <priority>AVERAGE</priority>
                                           <description>Last value: {ITEM.LASTVALUE1}.
       It may become impossible to write to disk if there are no index nodes left.
       As symptoms, 'No space left on device' or 'Disk is full' errors may be seen even though free space is available.</description>
                                       </trigger_prototype>
                                       <trigger_prototype>
                                           <expression>{min(5m)}<{$VFS.FS.INODE.PFREE.MIN.WARN:"{#FSNAME}"}</expression>
                                           <name>{#FSNAME}: Running out of free inodes (free < {$VFS.FS.INODE.PFREE.MIN.WARN:"{#FSNAME}"}%)</name>
                                           <priority>WARNING</priority>
                                           <description>Last value: {ITEM.LASTVALUE1}.
       It may become impossible to write to disk if there are no index nodes left.
       As symptoms, 'No space left on device' or 'Disk is full' errors may be seen even though free space is available.</description>
                                           <dependencies>
                                               <dependency>
                                                   <name>{#FSNAME}: Running out of free inodes (free < {$VFS.FS.INODE.PFREE.MIN.CRIT:"{#FSNAME}"}%)</name>
                                                   <expression>{Template Module Linux filesystems by Zabbix agent:vfs.fs.inode[{#FSNAME},pfree].min(5m)}<{$VFS.FS.INODE.PFREE.MIN.CRIT:"{#FSNAME}"}</expression>
                                               </dependency>
                                           </dependencies>
                                       </trigger_prototype>
                                   </trigger_prototypes>
                               </item_prototype>
                               <item_prototype>
                                   <name>{#FSNAME}: Space utilization</name>
                                   <key>vfs.fs.size[{#FSNAME},pused]</key>
                                   <history>7d</history>
                                   <value_type>FLOAT</value_type>
                                   <units>%</units>
                                   <description>Space utilization in % for {#FSNAME}</description>
                                   <application_prototypes>
                                       <application_prototype>
                                           <name>Filesystem {#FSNAME}</name>
                                       </application_prototype>
                                   </application_prototypes>
                               </item_prototype>
                               <item_prototype>
                                   <name>{#FSNAME}: Total space</name>
                                   <key>vfs.fs.size[{#FSNAME},total]</key>
                                   <history>7d</history>
                                   <units>B</units>
                                   <description>Total space in Bytes</description>
                                   <application_prototypes>
                                       <application_prototype>
                                           <name>Filesystem {#FSNAME}</name>
                                       </application_prototype>
                                   </application_prototypes>
                               </item_prototype>
                               <item_prototype>
                                   <name>{#FSNAME}: Used space</name>
                                   <key>vfs.fs.size[{#FSNAME},used]</key>
                                   <history>7d</history>
                                   <units>B</units>
                                   <description>Used storage in Bytes</description>
                                   <application_prototypes>
                                       <application_prototype>
                                           <name>Filesystem {#FSNAME}</name>
                                       </application_prototype>
                                   </application_prototypes>
                               </item_prototype>
                           </item_prototypes>
                           <trigger_prototypes>
                               <trigger_prototype>
                                   <expression>{Template Module Linux filesystems by Zabbix agent:vfs.fs.size[{#FSNAME},pused].last()}>{$VFS.FS.PUSED.MAX.CRIT:"{#FSNAME}"} and
       (({Template Module Linux filesystems by Zabbix agent:vfs.fs.size[{#FSNAME},total].last()}-{Template Module Linux filesystems by Zabbix agent:vfs.fs.size[{#FSNAME},used].last()})<5G or {Template Module Linux filesystems by Zabbix agent:vfs.fs.size[{#FSNAME},pused].timeleft(1h,,100)}<1d)</expression>
                                   <name>{#FSNAME}: Disk space is critically low (used > {$VFS.FS.PUSED.MAX.CRIT:"{#FSNAME}"}%)</name>
                                   <priority>AVERAGE</priority>
                                   <description>Last value: {ITEM.LASTVALUE1}.
       Space used: {ITEM.VALUE3} of {ITEM.VALUE2} ({ITEM.VALUE1}), time left till full: < 24h.
       Two conditions should match: First, space utilization should be above {$VFS.FS.PUSED.MAX.CRIT:"{#FSNAME}"}.
        Second condition should be one of the following:
        - The disk free space is less than 5G.
        - The disk will be full in less than 24hours.</description>
                                   <manual_close>YES</manual_close>
                               </trigger_prototype>
                               <trigger_prototype>
                                   <expression>{Template Module Linux filesystems by Zabbix agent:vfs.fs.size[{#FSNAME},pused].last()}>{$VFS.FS.PUSED.MAX.WARN:"{#FSNAME}"} and
       (({Template Module Linux filesystems by Zabbix agent:vfs.fs.size[{#FSNAME},total].last()}-{Template Module Linux filesystems by Zabbix agent:vfs.fs.size[{#FSNAME},used].last()})<10G or {Template Module Linux filesystems by Zabbix agent:vfs.fs.size[{#FSNAME},pused].timeleft(1h,,100)}<1d)</expression>
                                   <name>{#FSNAME}: Disk space is low (used > {$VFS.FS.PUSED.MAX.WARN:"{#FSNAME}"}%)</name>
                                   <priority>WARNING</priority>
                                   <description>Last value: {ITEM.LASTVALUE1}.
       Space used: {ITEM.VALUE3} of {ITEM.VALUE2} ({ITEM.VALUE1}), time left till full: < 24h.
       Two conditions should match: First, space utilization should be above {$VFS.FS.PUSED.MAX.CRIT:"{#FSNAME}"}.
        Second condition should be one of the following:
        - The disk free space is less than 10G.
        - The disk will be full in less than 24hours.</description>
                                   <manual_close>YES</manual_close>
                                   <dependencies>
                                       <dependency>
                                           <name>{#FSNAME}: Disk space is critically low (used > {$VFS.FS.PUSED.MAX.CRIT:"{#FSNAME}"}%)</name>
                                           <expression>{Template Module Linux filesystems by Zabbix agent:vfs.fs.size[{#FSNAME},pused].last()}>{$VFS.FS.PUSED.MAX.CRIT:"{#FSNAME}"} and
       (({Template Module Linux filesystems by Zabbix agent:vfs.fs.size[{#FSNAME},total].last()}-{Template Module Linux filesystems by Zabbix agent:vfs.fs.size[{#FSNAME},used].last()})<5G or {Template Module Linux filesystems by Zabbix agent:vfs.fs.size[{#FSNAME},pused].timeleft(1h,,100)}<1d)</expression>
                                       </dependency>
                                   </dependencies>
                               </trigger_prototype>
                           </trigger_prototypes>
                           <graph_prototypes>
                               <graph_prototype>
                                   <name>{#FSNAME}: Disk space usage</name>
                                   <width>600</width>
                                   <height>340</height>
                                   <type>PIE</type>
                                   <show_3d>YES</show_3d>
                                   <graph_items>
                                       <graph_item>
                                           <color>969696</color>
                                           <calc_fnc>LAST</calc_fnc>
                                           <type>GRAPH_SUM</type>
                                           <item>
                                               <host>Template Module Linux filesystems by Zabbix agent</host>
                                               <key>vfs.fs.size[{#FSNAME},total]</key>
                                           </item>
                                       </graph_item>
                                       <graph_item>
                                           <sortorder>1</sortorder>
                                           <color>C80000</color>
                                           <calc_fnc>LAST</calc_fnc>
                                           <item>
                                               <host>Template Module Linux filesystems by Zabbix agent</host>
                                               <key>vfs.fs.size[{#FSNAME},used]</key>
                                           </item>
                                       </graph_item>
                                   </graph_items>
                               </graph_prototype>
                           </graph_prototypes>
                       </discovery_rule>
                   </discovery_rules>
                   <macros>
                       <macro>
                           <macro>{$VFS.FS.FSNAME.MATCHES}</macro>
                           <value>.+</value>
                       </macro>
                       <macro>
                           <macro>{$VFS.FS.FSNAME.NOT_MATCHES}</macro>
                           <value>^(/dev|/sys|/run|/proc|.+/shm$)</value>
                       </macro>
                       <macro>
                           <macro>{$VFS.FS.FSTYPE.MATCHES}</macro>
                           <value>^(btrfs|ext2|ext3|ext4|reiser|xfs|ffs|ufs|jfs|jfs2|vxfs|hfs|apfs|refs|ntfs|fat32|zfs)$</value>
                       </macro>
                       <macro>
                           <macro>{$VFS.FS.FSTYPE.NOT_MATCHES}</macro>
                           <value>^\s$</value>
                       </macro>
                       <macro>
                           <macro>{$VFS.FS.INODE.PFREE.MIN.CRIT}</macro>
                           <value>10</value>
                       </macro>
                       <macro>
                           <macro>{$VFS.FS.INODE.PFREE.MIN.WARN}</macro>
                           <value>20</value>
                       </macro>
                       <macro>
                           <macro>{$VFS.FS.PUSED.MAX.CRIT}</macro>
                           <value>90</value>
                       </macro>
                       <macro>
                           <macro>{$VFS.FS.PUSED.MAX.WARN}</macro>
                           <value>80</value>
                       </macro>
                   </macros>
               </template>
           </templates>
       </zabbix_export>

Element tags

Element tag values are explained in the table below.

Template tags
Element Element property Required Type Range Description
templates - Root element for templates.
template - Individual template.
template x string Unique template name.
name - string Visible template name.
description - text Template description.
groups x Root element for template host groups.
group x Individual template host group.
name x string Host group name.
applications - Root element for template applications.
application - Individual template application.
name x string Application name.
macros - Root element for template user macros.
macro - Individual template user macro.
macro x string User macro name.
value - string User macro value.
tags - Root element for template tags.
tag - Individual template tag.
tag x string Tag name.
value - string Tag value.
templates - Root element for linked templates.
template - Individual linked template.
name x string Template name.
Template item tags
Element Element property Required Type Range1 Description
items - Root element for items.
item - Individual item.
name x string Item name.
type - string 0 - ZABBIX_PASSIVE (default)
1 - SNMPV1
2 - TRAP
3 - SIMPLE
4 - SNMPV2
5 - INTERNAL
6 - SNMPV3
7 - ZABBIX_ACTIVE
8 - AGGREGATE
10 - EXTERNAL
11 - ODBC
12 - IPMI
13 - SSH
14 - TELNET
15 - CALCULATED
16 - JMX
17 - SNMP_TRAP
18 - DEPENDENT
19 - HTTP_AGENT
Item type.
snmp_community - string SNMP community.

Required by SNMPv1 and SNMPv2 items.
snmp_oid - string SNMP object ID.

Required by SNMP items.
key x string Item key.
delay - string Default: 1m Update interval of the item.

Accepts seconds or a time unit with suffix (30s, 1m, 2h, 1d).
Optionally one or more custom intervals can be specified either as flexible intervals or scheduling.
Multiple intervals are separated by a semicolon.
User macros may be used. A single macro has to fill the whole field. Multiple macros in a field or macros mixed with text are not supported.
Flexible intervals may be written as two macros separated by a forward slash (e.g. {$FLEX_INTERVAL}/{$FLEX_PERIOD}).
history - string Default: 90d A time unit of how long the history data should be stored. Time unit with suffix, user macro or LLD macro.
trends - string Default: 365d A time unit of how long the trends data should be stored. Time unit with suffix, user macro or LLD macro.
status - string 0 - ENABLED (default)
1 - DISABLED
Item status.
value_type - string 0 - FLOAT
1 - CHAR
2 - LOG
3 - UNSIGNED (default)
4 - TEXT
Received value type.
allowed_hosts - string List of IP addresses (comma delimited) of hosts allowed sending data for the item.

Used by trapper and HTTP agent items.
units - string Units of returned values (bps, B, etc).
snmpv3_contextname - string SNMPv3 context name.

Used only by SNMPv3 items.
snmpv3_securityname - string SNMPv3 security name.

Used only by SNMPv3 items.
snmpv3_securitylevel - string 0 - NOAUTHNOPRIV (default)
1 - AUTHNOPRIV
2 - AUTHPRIV
SNMPv3 security level.

Used only by SNMPv3 items.
snmpv3_authprotocol - string 0 - MD5 (default)
1 - SHA
SNMPv3 authentication protocol.

Used only by SNMPv3 items.
snmpv3_authpassphrase - string SNMPv3 authentication passphrase.

Used only by SNMPv3 items.
snmpv3_privprotocol - string 0 - DES (default)
1 - AES
SNMPv3 privacy protocol.

Used only by SNMPv3 items.
snmpv3_privpassphrase - string SNMPv3 privacy passphrase.

Used only by SNMPv3 items.
params - text Additional parameters depending on the type of the item:
- executed script for SSH and Telnet items;
- SQL query for database monitor items;
- formula for calculated items.
ipmi_sensor - string IPMI sensor.

Used only by IPMI items.
authtype - string Authentication type for SSH agent items:
0 - PASSWORD (default)
1 - PUBLIC_KEY

Authentication type for HTTP agent items:
0 - NONE (default)
1 - BASIC
2 - NTLM
Authentication type.

Used only by SSH and HTTP agent items.
username - string Username for authentication.
Used by simple check, SSH, Telnet, database monitor, JMX and HTTP agent items.

Required by SSH and Telnet items.
When used by JMX agent, password should also be specified together with the username or both properties should be left blank.
password - string Password for authentication.
Used by simple check, SSH, Telnet, database monitor, JMX and HTTP agent items.

When used by JMX agent, username should also be specified together with the password or both properties should be left blank.
publickey - string Name of the public key file.

Required for SSH agent items.
privatekey - string Name of the private key file.

Required for SSH agent items.
port - string Custom port monitored by the item.
Can contain user macros.

Used only by SNMP items.
description - text Item description.
inventory_link - string 0 - NONE

Capitalized host inventory field name. For example:
4 - ALIAS
6 - OS_FULL
14 - HARDWARE
etc.
Host inventory field that is populated by the item.

Refer to the host inventory page for a list of supported host inventory fields and their IDs.
logtimefmt - string Format of the time in log entries.
Used only by log items.
jmx_endpoint - string JMX endpoint.

Used only by JMX agent items.
url - string URL string.

Required only for HTTP agent items.
allow_traps - string 0 - NO (default)
1 - YES
Allow to populate value as in a trapper item.

Used only by HTTP agent items.
follow_redirects - string 0 - NO
1 - YES (default)
Follow HTTP response redirects while pooling data.

Used only by HTTP agent items.
headers - Root element for HTTP(S) request headers, where header name is used as key and header value as value.
Used only by HTTP agent items.
header - Individual header.
name x string Header name.
value x string Header value.
http_proxy - string HTTP(S) proxy connection string.

Used only by HTTP agent items.
output_format - string 0 - RAW (default)
1 - JSON
How to process response.

Used only by HTTP agent items.
post_type - string 0 - RAW (default)
2 - JSON
3 - XML
Type of post data body.

Used only by HTTP agent items.
posts - string HTTP(S) request body data.

Used only by HTTP agent items.
query_fields - Root element for query parameters.

Used only by HTTP agent items.
query_field - Individual query parameter.
name x string Parameter name.
value - string Parameter value.
request_method - string 0 - GET (default)
1 - POST
2 - PUT
3 - HEAD
Request method.

Used only by HTTP agent items.
retrieve_mode - string 0 - BODY (default)
1 - HEADERS
2 - BOTH
What part of response should be stored.

Used only by HTTP agent items.
ssl_cert_file - string Public SSL Key file path.

Used only by HTTP agent items.
ssl_key_file - string Private SSL Key file path.

Used only by HTTP agent items.
ssl_key_password - string Password for SSL Key file.

Used only by HTTP agent items.
status_codes - string Ranges of required HTTP status codes separated by commas. Supports user macros.
Example: 200,200-{$M},{$M},200-400

Used only by HTTP agent items.
timeout - string Item data polling request timeout. Supports user macros.

Used only by HTTP agent items.
verify_host - string 0 - NO (default)
1 - YES
Validate if host name in URL is in Common Name field or a Subject Alternate Name field of host certificate.

Used only by HTTP agent items.
verify_peer - string 0 - NO (default)
1 - YES
Validate if host certificate is authentic.

Used only by HTTP agent items.
value map - Value map.
name x string Name of the value map to use for the item.
applications - Root element for applications.
application - Individual application.
name x string Application name.
preprocessing - Root element for item value preprocessing.
step - Individual item value preprocessing step.
type x string 1 - MULTIPLIER
2 - RTRIM
3 - LTRIM
4 - TRIM
5 - REGEX
6 - BOOL_TO_DECIMAL
7 - OCTAL_TO_DECIMAL
8 - HEX_TO_DECIMAL
9 - SIMPLE_CHANGE (calculated as (received value-previous value))
10 - CHANGE_PER_SECOND (calculated as (received value-previous value)/(time now-time of last check))
11 - XMLPATH
12 - JSONPATH
13 - IN_RANGE
14 - MATCHES_REGEX
15 - NOT_MATCHES_REGEX
16 - CHECK_JSON_ERROR
17 - CHECK_XML_ERROR
18 - CHECK_REGEX_ERROR
19 - DISCARD_UNCHANGED
20 - DISCARD_UNCHANGED_HEARTBEAT
21 - JAVASCRIPT
22 - PROMETHEUS_PATTERN
23 - PROMETHEUS_TO_JSON
24 - CSV_TO_JSON
Type of the item value preprocessing step.
params x string Parameters of the item value preprocessing step.

Multiple parameters are separated by LF (\n) character.
error_handler - string 0 - ORIGINAL_ERROR (default)
1 - DISCARD_VALUE
2 - CUSTOM_VALUE
3 - CUSTOM_ERROR
Action type used in case of preprocessing step failure.
error_handler_params - string Error handler parameters used with 'error_handler'.
master_item - Individual item master item.

Required by dependent items.
key x string Dependent item master item key value.

Recursion up to 3 dependent items and maximum count of dependent items equal to 29999 are allowed.
triggers - Root element for simple triggers.
trigger - Individual simple trigger.
For trigger element tag values, see template trigger tags.
Template low-level discovery rule tags
Element Element property Required Type Range Description
discovery_rules - Root element for low-level discovery rules.
discovery_rule - Individual low-level discovery rule.
For most of the element tag values, see element tag values for a regular item. Only the tags that are specific to low-level discovery rules, are described below.
type - string 0 - ZABBIX_PASSIVE (default)
1 - SNMPV1
2 - TRAP
3 - SIMPLE
4 - SNMPV2
5 - INTERNAL
6 - SNMPV3
7 - ZABBIX_ACTIVE
10 - EXTERNAL
11 - ODBC
12 - IPMI
13 - SSH
14 - TELNET
16 - JMX
18 - DEPENDENT
19 - HTTP_AGENT
Item type.
lifetime - string Default: 30d Time period after which items that are no longer discovered will be deleted. Seconds, time unit with suffix or user macro.
filter Individual filter.
evaltype - string 0 - AND_OR (default)
1 - AND
2 - OR
3 - FORMULA
Logic to use for checking low-level discovery rule filter conditions.
formula - string Custom calculation formula for filter conditions.
conditions - Root element for filter conditions.
condition - Individual filter condition.
macro x string Low-level discovery macro name.
value - string Filter value: regular expression or global regular expression.
operator - string 8 - MATCHES_REGEX (default)
9 - NOT_MATCHES_REGEX
Condition operator.
formulaid x character Arbitrary unique ID that is used to reference a condition from the custom expression. Can only contain capital-case letters. The ID must be defined by the user when modifying filter conditions, but will be generated anew when requesting them afterward.
lld_macro_paths - Root element for LLD macro paths.
lld_macro_path - Individual LLD macro path.
lld_macro x string Low-level discovery macro name.
path x string Selector for value which will be assigned to the corresponding macro.
preprocessing - LLD rule value preprocessing.
step - Individual LLD rule value preprocessing step.
For most of the element tag values, see element tag values for a template item value preprocessing. Only the tags that are specific to template low-level discovery value preprocessing, are described below.
type x string 5 - REGEX
11 - XMLPATH
12 - JSONPATH
15 - NOT_MATCHES_REGEX
16 - CHECK_JSON_ERROR
17 - CHECK_XML_ERROR
20 - DISCARD_UNCHANGED_HEARTBEAT
21 - JAVASCRIPT
23 - PROMETHEUS_TO_JSON
24 - CSV_TO_JSON
Type of the item value preprocessing step.
trigger_prototypes - Root element for trigger prototypes.
trigger_prototype - Individual trigger prototype.
For trigger prototype element tag values, see regular template trigger tags.
graph_prototypes - Root element for graph prototypes.
graph_prototype - Individual graph prototype.
For graph prototype element tag values, see regular template graph tags.
host_prototypes - Root element for host prototypes.
host_prototype - Individual host prototype.
For host prototype element tag values, see regular host tags.
item_prototypes - Root element for item prototypes.
item_prototype - Individual item prototype.
For item prototype element tag values, see regular template item tags.
application_prototypes - Root element for application prototypes.
application_prototype - Individual application prototype.
name x string Application prototype name.
master_item - Individual item prototype master item/item prototype data.
key x string Dependent item prototype master item/item prototype key value.

Required for a dependent item.
Template trigger tags
Element Element property Required Type Range1 Description
triggers - Root element for triggers.
trigger - Individual trigger.
expression x string Trigger expression.
recovery_mode - string 0 - EXPRESSION (default)
1 - RECOVERY_EXPRESSION
2 - NONE
Basis for generating OK events.
recovery_expression - string Trigger recovery expression.
name x string Trigger name.
correlation_mode - string 0 - DISABLED (default)
1 - TAG_VALUE
Correlation mode (no event correlation or event correlation by tag).
correlation_tag - string The tag name to be used for event correlation.
url - string URL associated with the trigger.
status - string 0 - ENABLED (default)
1 - DISABLED
Trigger status.
priority - string 0 - NOT_CLASSIFIED (default)
1 - INFO
2 - WARNING
3 - AVERAGE
4 - HIGH
5 - DISASTER
Trigger severity.
description - text Trigger description.
type - string 0 - SINGLE (default)
1 - MULTIPLE
Event generation type (single problem event or multiple problem events).
manual_close - string 0 - NO (default)
1 - YES
Manual closing of problem events.
dependencies - Root element for dependencies.
dependency - Individual trigger dependency.
name x string Dependency trigger name.
expression x string Dependency trigger expression.
recovery_expression - string Dependency trigger recovery expression.
tags - Root element for event tags.
tag - Individual event tag.
tag x string Tag name.
value - string Tag value.
Template graph tags
Element Element property Required Type Range1 Description
graphs - Root element for graphs.
graph - Individual graph.
name x string Graph name.
width - integer 20-65535 (default: 900) Graph width, in pixels. Used for preview and for pie/exploded graphs.
height - integer 20-65535 (default: 200) Graph height, in pixels. Used for preview and for pie/exploded graphs.
yaxismin - double Default: 0 Value of Y axis minimum.

Used if 'ymin_type_1' is FIXED.
yaxismax - double Default: 0 Value of Y axis maximum.

Used if 'ymax_type_1' is FIXED.
show_work_period - string 0 - NO
1 - YES (default)
Highlight non-working hours.

Used by normal and stacked graphs.
show_triggers - string 0 - NO
1 - YES (default)
Display simple trigger values as a line.

Used by normal and stacked graphs.
type - string 0 - NORMAL (default)
1 - STACKED
2 - PIE
3 - EXPLODED
Graph type.
show_legend - string 0 - NO
1 - YES (default)
Display graph legend.
show_3d - string 0 - NO (default)
1 - YES
Enable 3D style.

Used by pie and exploded pie graphs.
percent_left - double Default:0 Show the percentile line for left axis.

Used only for normal graphs.
percent_right - double Default:0 Show the percentile line for right axis.

Used only for normal graphs.
ymin_type_1 - string 0 - CALCULATED (default)
1 - FIXED
2 - ITEM
Minimum value of Y axis.

Used by normal and stacked graphs.
ymax_type_1 - string 0 - CALCULATED (default)
1 - FIXED
2 - ITEM
Maximum value of Y axis.

Used by normal and stacked graphs.
ymin_item_1 - Individual item details.

Required if 'ymin_type_1' is ITEM.
host x string Item host.
key x string Item key.
ymax_item_1 - Individual item details.

Required if 'ymax_type_1' is ITEM.
host x string Item host.
key x string Item key.
graph_items x Root element for graph items.
graph_item x Individual graph item.
sortorder - integer Draw order. The smaller value is drawn first. Can be used to draw lines or regions behind (or in front of) another.
drawtype - string 0 - SINGLE_LINE (default)
1 - FILLED_REGION
2 - BOLD_LINE
3 - DOTTED_LINE
4 - DASHED_LINE
5 - GRADIENT_LINE
Draw style of the graph item.

Used only by normal graphs.
color - string Element colour (6 symbols, hex).
yaxisside - string 0 - LEFT (default)
1 - RIGHT
Side of the graph where the graph item's Y scale will be drawn.

Used by normal and stacked graphs.
calc_fnc - string 1 - MIN
2 - AVG (default)
4 - MAX
7 - ALL (minimum, average and maximum; used only by simple graphs)
9 - LAST (used only by pie and exploded pie graphs)
Data to draw if more than one value exists for an item.
type - string 0 - SIMPLE (default)
2 - GRAPH_SUM (value of the item represents the whole pie; used only by pie and exploded pie graphs)
Graph item type.
item x Individual item.
host x string Item host.
key x string Item key.
Template web scenario tags
Element Element property Required Type Range1 Description
httptests - Root element for web scenarios.
httptest - Individual web scenario.
name x string Web scenario name.
delay - string Default: 1m Frequency of executing the web scenario. Seconds, time unit with suffix or user macro.
attempts - integer 1-10 (default: 1) The number of attempts for executing web scenario steps.
agent - string Default: Zabbix Client agent. Zabbix will pretend to be the selected browser. This is useful when a website returns different content for different browsers.
http_proxy - string Specify an HTTP proxy to use, using the format: http://[username[:password]@]proxy.mycompany.com[:port]
variables - Root element for scenario-level variables (macros) that may be used in scenario steps.
variable - Individual variable.
name x text Variable name.
value x text Variable value.
headers - Root element for HTTP headers that will be sent when performing a request. Headers should be listed using the same syntax as they would appear in the HTTP protocol.
header - Individual header.
name x text Header name.
value x text Header value.
status - string 0 - ENABLED (default)
1 - DISABLED
Web scenario status.
authentication - string 0 - NONE (default)
1 - BASIC
2 - NTLM
Authentication method.
http_user - string User name used for basic, HTTP or NTLM authentication.
http_password - string Password used for basic, HTTP or NTLM authentication.
verify_peer - string 0 - NO (default)
1 - YES
Verify the SSL certificate of the web server.
verify_host - string 0 - NO (default)
1 - YES
Verify that the Common Name field or the Subject Alternate Name field of the web server certificate matches.
ssl_cert_file - string Name of the SSL certificate file used for client authentication (must be in PEM format).
ssl_key_file - string Name of the SSL private key file used for client authentication (must be in PEM format).
ssl_key_password - string SSL private key file password.
steps x Root element for web scenario steps.
step x Individual web scenario step.
name x string Web scenario step name.
url x string URL for monitoring.
query_fields - Root element for query fields - an array of HTTP fields that will be added to the URL when performing a request.
query_field - Individual query field.
name x string Query field name.
value - string Query field value.
posts - HTTP POST variables as a string (raw post data) or as an array of HTTP fields (form field data).
post_field - Individual post field.
name x string Post field name.
value x string Post field value.
variables - Root element of step-level variables (macros) that should be applied after this step.

If the variable value has a 'regex:' prefix, then its value is extracted from the data returned by this step according to the regular expression pattern following the 'regex:' prefix
variable - Individual variable.
name x string Variable name.
value x string Variable value.
headers - Root element for HTTP headers that will be sent when performing a request. Headers should be listed using the same syntax as they would appear in the HTTP protocol.
header - Individual header.
name x string Header name.
value x string Header value.
follow_redirects - string 0 - NO
1 - YES (default)
Follow HTTP redirects.
retrieve_mode - string 0 - BODY (default)
1 - HEADERS
2 - BOTH
HTTP response retrieve mode.
timeout - string Default: 15s Timeout of step execution. Seconds, time unit with suffix or user macro.
required - string Text that must be present in the response. Ignored if empty.
status_codes - string A comma delimited list of accepted HTTP status codes. Ignored if empty. For example: 200-201,210-299
Template screen tags
Element Element property Required Type Range1 Description
screens - Root element for template screens.
screen - Individual template screen.
screen_items - Root element for template screen items.
screen_item - Individual template screen item.
Footnotes

1 For string values, only the string will be exported (e.g. "ZABBIX_ACTIVE") without the numbering used in this table. The numbers for range values (corresponding to the API values) in this table is used for ordering only.