# salt.states.zabbix_mediatype

Warning

This module will be removed from Salt in version 3009 in favor of the zabbix Salt Extension.

Management of Zabbix mediatypes.

codeauthor:

  Raymond Kuiper <qix@the-wired.net>

salt.states.zabbix_mediatype.absent(name, **kwargs)

  Ensures that the mediatype does not exist, eventually deletes the mediatype.

  Parameters:

    - name -- name of the mediatype

    - _connection_user -- Optional - zabbix user (can also be set in opts or pillar, see module's docstring)

    - _connection_password -- Optional - zabbix password (can also be set in opts or pillar, see module's docstring)

    - _connection_url -- Optional - url of zabbix frontend (can also be set in opts, pillar, see module's docstring)

      delete_mediatype:
          zabbix_mediatype.absent:
              - name: 'Email'

salt.states.zabbix_mediatype.present(name, mediatype, **kwargs)

  Creates new mediatype. NOTE: This function accepts all standard mediatype properties: keyword argument names differ depending on your zabbix version, see: https://www.zabbix.com/documentation/3.0/manual/api/reference/host/object#host_inventory

  Parameters:

    - name -- name of the mediatype

    - _connection_user -- Optional - zabbix user (can also be set in opts or pillar, see module's docstring)

    - _connection_password -- Optional - zabbix password (can also be set in opts or pillar, see module's docstring)

    - _connection_url -- Optional - url of zabbix frontend (can also be set in opts, pillar, see module's docstring)

      make_new_mediatype:
          zabbix_mediatype.present:
              - name: 'Email'
              - mediatype: 0
              - smtp_server: smtp.example.com
              - smtp_hello: zabbix.example.com
              - smtp_email: zabbix@example.com