title: How to resolve ‘530 5.7.0 Must issue a STARTTLS command first. o63-v6sm4041934ywc.36 - gsmtp\n’ for elasticsearch?
body: <p>I am creating an application where I need to send an email alert for my logs.
  Here is input to create a watcher:</p>
  
  <pre><code>PUT _xpack/watcher/watch/log_error_watch
  {
    "trigger" : {
      "schedule" : { "interval" : "10s" } 
    },
    "input" : {
      "search" : {
        "request" : {
          "indices" : [ "testindexv4" ],
          "body" : {
            "query" : {
              "match" : { "log_level": "ERROR" }
            }
          }
        }
      }
    }
    ,
    "actions" : {
    "send_email" : { 
      "email" : { 
        "to" : "&lt;mailId&gt;@gmail.com", 
        "subject" : "Watcher Notification", 
        "body" : "error logs found" 
      }
    }
  }
  }
  </code></pre>
  
  <p>Here is configuration for elasticsearch.yml</p>
  
  <pre><code>xpack.security.enabled: false
  xpack.notification.email.account:
        standard_account:
           profile: standard
           smtp:
               auth: false
               starttls.enable: false
               starttls.required: false
               host: smtp.gmail.com
               port: 587
  </code></pre>
  
  <p>When I try to run my watcher, I get the error as:</p>
  
  <p><code>reason": "530 5.7.0 Must issue a STARTTLS command first. o63-v6sm4041934ywc.36 - gsmtp\n</code> </p>
  
  <p>any solution on the same please?</p>