Resource URL: /platform/<<version=1>>/cluster/email

    Overview: This resource represents the cluster email notification settings.

     Methods: GET, PUT

********************************************************************************

Method GET: Get the cluster email notification settings.

       URL: GET /platform/<<version=1>>/cluster/email

There are no query arguments for this method.

GET response body schema:
{
  "type": "object", 
  "properties": {
    "settings": {
      "type": "object", 
      "description": "Cluster email notification settings.", 
      "properties": {
        "smtp_auth_security": {
          "enum": [
            "none", 
            "starttls"
          ], 
          "type": "string", 
          "description": "The type of secure communication protocol to use if SMTP is being used.  If 'none', plain text will be used, if 'starttls', the encrypted STARTTLS protocol will be used.", 
          "required": true
        }, 
        "user_template": {
          "required": true, 
          "type": [
            "string", 
            "null"
          ], 
          "description": "Location of a custom template file that can be used to specify the layout of the notification emails."
        }, 
        "use_smtp_auth": {
          "required": true, 
          "type": "boolean", 
          "description": "If true, this cluster will send SMTP authentication credentials to the SMTP relay server in order to send its notification emails.  If false, the cluster will attempt to send its notification emails without authentication."
        }, 
        "smtp_auth_username": {
          "required": true, 
          "type": "string", 
          "description": "Username to authenticate with if SMTP authentication is being used."
        }, 
        "smtp_port": {
          "required": true, 
          "type": "integer", 
          "description": "The port on the SMTP server to be used for relaying the notification messages.  "
        }, 
        "mail_subject": {
          "required": true, 
          "type": "string", 
          "description": "The subject line for notification messages from this cluster."
        }, 
        "mail_sender": {
          "required": true, 
          "type": "string", 
          "description": "The full email address that will appear as the sender of notification messages."
        }, 
        "mail_relay": {
          "required": true, 
          "type": "string", 
          "description": "The address of the SMTP server to be used for relaying the notification messages.  An SMTP server is required in order to send notifications.  If this string is empty, no emails will be sent."
        }, 
        "smtp_auth_passwd_set": {
          "required": true, 
          "type": "boolean", 
          "description": "Indicates if an SMTP authentication password is set."
        }, 
        "batch_mode": {
          "enum": [
            "all", 
            "severity", 
            "category", 
            "none"
          ], 
          "type": "string", 
          "description": "This setting determines how notifications will be batched together to be sent by email.  'none' means each notification will be sent separately.  'severity' means notifications of the same severity will be sent together.  'category' means notifications of the same category will be sent together.  'all' means all notifications will be batched together and sent in a single email.", 
          "required": true
        }
      }
    }
  }
}

********************************************************************************

Method PUT: Modify the cluster email notification settings.  All input fields
            are optional, but one or more must be supplied.

       URL: PUT /platform/<<version=1>>/cluster/email

There are no query arguments for this method.

PUT request body schema:
{
  "type": "object", 
  "description": "Cluster email notification settings.", 
  "properties": {
    "smtp_auth_security": {
      "enum": [
        "none", 
        "starttls"
      ], 
      "type": "string", 
      "description": "The type of secure communication protocol to use if SMTP is being used.  If 'none', plain text will be used, if 'starttls', the encrypted STARTTLS protocol will be used."
    }, 
    "user_template": {
      "type": [
        "string", 
        "null"
      ], 
      "description": "Location of a custom template file that can be used to specify the layout of the notification emails."
    }, 
    "use_smtp_auth": {
      "type": "boolean", 
      "description": "If true, this cluster will send SMTP authentication credentials to the SMTP relay server in order to send its notification emails.  If false, the cluster will attempt to send its notification emails without authentication."
    }, 
    "smtp_auth_username": {
      "type": "string", 
      "description": "Username to authenticate with if SMTP authentication is being used."
    }, 
    "smtp_port": {
      "type": "integer", 
      "description": "The port on the SMTP server to be used for relaying the notification messages.  "
    }, 
    "mail_subject": {
      "type": "string", 
      "description": "The subject line for notification messages from this cluster."
    }, 
    "smtp_auth_passwd": {
      "type": [
        "string", 
        "null"
      ], 
      "description": "Password to authenticate with if SMTP authentication is being used."
    }, 
    "mail_sender": {
      "type": "string", 
      "description": "The full email address that will appear as the sender of notification messages."
    }, 
    "mail_relay": {
      "type": "string", 
      "description": "The address of the SMTP server to be used for relaying the notification messages.  An SMTP server is required in order to send notifications.  If this string is empty, no emails will be sent."
    }, 
    "batch_mode": {
      "enum": [
        "all", 
        "severity", 
        "category", 
        "none"
      ], 
      "type": "string", 
      "description": "This setting determines how notifications will be batched together to be sent by email.  'none' means each notification will be sent separately.  'severity' means notifications of the same severity will be sent together.  'category' means notifications of the same category will be sent together.  'all' means all notifications will be batched together and sent in a single email."
    }
  }
}

There is no response body for this method.
