zabbix_export:
  version: '7.4'
  host_groups:
    - uuid: f2481361f99448eea617b7b1d4765566
      name: 'Discovered hosts'
  hosts:
    - host: test
      name: test
      groups:
        - name: 'Discovered hosts'
      interfaces:
        - interface_ref: if1
      discovery_rules:
        - name: '3rd level LLD'
          type: NESTED
          key: 'lld_trap[{#L0},{#L1},{#L2}]'
          item_prototypes:
            - name: '3rd Level item prototype {#L0} {#L3}'
              type: TRAP
              key: 'trap3[{#L0},{#L1},{#L2},{#L3}]'
          parent_discovery_rule:
            key: 'lld_trap[{#L0},{#L1}]'
          lld_macro_paths:
            - lld_macro: '{#L3}'
              path: $.level_3
          preprocessing:
            - type: JSONPATH
              parameters:
                - $.path_to_3
        - name: '2nd level LLD'
          type: NESTED
          key: 'lld_trap[{#L0},{#L1}]'
          item_prototypes:
            - name: '2nd level Item prototype'
              type: TRAP
              key: 'trap2[{#L0},{#L1},{#L2}]'
              trigger_prototypes:
                - expression: 'last(/test/trap2[{#L0},{#L1},{#L2}])<>2'
                  name: '2nd level trigger prototype'
                  priority: WARNING
          graph_prototypes:
            - name: '2nd level Graph prototype {#L0} {#L1} {#L2}'
              graph_items:
                - color: 1A7C11
                  calc_fnc: ALL
                  item:
                    host: test
                    key: 'trap2[{#L0},{#L1},{#L2}]'
          host_prototypes:
            - host: '2nd level host prototype {#L0} {#L1} {#L2}'
              name: '2nd level host prototype {#L0} {#L1} {#L2}'
              group_links:
                - group:
                    name: 'Discovered hosts'
          parent_discovery_rule:
            key: 'lld_trap[{#L0}]'
          lld_macro_paths:
            - lld_macro: '{#L2}'
              path: $.level_2
          preprocessing:
            - type: JSONPATH
              parameters:
                - $.path_to_2
        - name: '1st level LLD'
          type: NESTED
          key: 'lld_trap[{#L0}]'
          item_prototypes:
            - name: '1st level item prototype'
              type: TRAP
              key: 'trap1[{#L0},{#L1}]'
              trigger_prototypes:
                - expression: 'last(/test/trap1[{#L0},{#L1}])<>1'
                  name: '1st level'
                  priority: WARNING
          graph_prototypes:
            - name: '1st level Graph prototype {#L0} {#L1}'
              graph_items:
                - color: 1A7C11
                  calc_fnc: ALL
                  item:
                    host: test
                    key: 'trap1[{#L0},{#L1}]'
          host_prototypes:
            - host: '1st Level Host prototype {#L0} {#L1}'
              name: '1st Level Host prototype {#L0} {#L1}'
              group_links:
                - group:
                    name: 'Discovered hosts'
          parent_discovery_rule:
            key: trap
          lld_macro_paths:
            - lld_macro: '{#L1}'
              path: $.level_1
          preprocessing:
            - type: JSONPATH
              parameters:
                - $.path_to_1
        - name: '0 level LLD'
          type: TRAP
          key: trap
          item_prototypes:
            - name: '0 level item prototype'
              type: TRAP
              key: 'trap0[{#L0}]'
              trigger_prototypes:
                - expression: 'last(/test/trap0[{#L0}])<>0'
                  name: '0 level Trigger prototype'
                  priority: WARNING
          graph_prototypes:
            - name: '0 level Graph prototype {#L0}'
              graph_items:
                - color: 1A7C11
                  calc_fnc: ALL
                  item:
                    host: test
                    key: 'trap0[{#L0}]'
          host_prototypes:
            - host: '0 level Host prototype {#L0}'
              name: '0 level Host prototype {#L0}'
              group_links:
                - group:
                    name: 'Discovered hosts'
          lld_macro_paths:
            - lld_macro: '{#L0}'
              path: $.level_0
