The email connector uses the SMTP protocol to send mail messages, using an integration of Nodemailer. Email message text is sent as both plain text and html text.
For emails to have a footer with a link back to Kibana, set the
server.publicBaseUrl configuration setting.
Email connectors have the following configuration properties.
- The name of the connector. The name is used to identify a connector in the management UI connector listing, or in the connector list when configuring an action.
The from address for all emails sent with this connector. This can be specified in
user@host-nameformat or as
"human name <user@host-name>"format. See the Nodemailer address documentation for more information.
Host name of the service provider. If you are using the
xpack.actions.allowedHostssetting, make sure this hostname is added to the allowed hosts.
- The port to connect to on the service provider.
- If true, the connection will use TLS when connecting to the service provider. Refer to the Nodemailer TLS documentation for more information. If not true, the connection will initially connect over TCP, then attempt to switch to TLS via the SMTP STARTTLS command.
- Require authentication
- If true, a username and password for login type authentication must be provided.
- Username for login type authentication.
- Password for login type authentication.
Preconfigured connector typeedit
my-email: name: preconfigured-email-connector-type actionTypeId: .email config: from: email@example.com host: validhostname port: 8080 secure: false secrets: user: testuser password: passwordkeystorevalue
Config defines information for the connector type.
The name of a well-known email service provider. If
secureproperties are ignored. For more information on the
gmailservice value, see the Nodemailer Gmail documentation.
- An email address that corresponds to Sender.
- A string that corresponds to Host.
- A number that corresponds to Port.
- A boolean that corresponds to Secure.
A boolean that corresponds to Requires authentication. If
true, this connector will require values for
passwordinside the secrets configuration. Defaults to
Secrets defines sensitive information for the connector type.
A string that corresponds to Username. Required if
hasAuthis set to
A string that corresponds to Password. Should be stored in the Kibana keystore. Required if
hasAuthis set to
Define connector in Stack Managementedit
Define email connector properties.
Test email action parameters.
Email actions have the following configuration properties.
- To, CC, BCC
Each item is a list of addresses. Addresses can be specified in
user@host-nameformat, or in
name <user@host-name>format. One of To, CC, or BCC must contain an entry.
- The subject line of the email.
- The message text of the email. Markdown format is supported.
Configuring email accounts for well-known servicesedit
The email connector can send email using many popular SMTP email services.
For more information about configuring the email connector to work with different email systems, refer to:
For other email servers, you can check the list of well-known services that Nodemailer supports in the JSON file well-known/services.json. The properties of the objects in those files —
secure — correspond to the same email connector configuration properties. A missing
secure property in the "well-known/services.json" file is considered
port: 465 uses
secure: true, and
port: 25 and
port: 587 use
Sending email from Elastic Cloudedit
These instructions require you to whitelist the email addresses that notifications get sent first.
Use the following connector settings to send email from Elastic Cloud:
- Toggle off
- Toggle off
Sending email from Gmailedit
Use the following email connector configuration to send email from the Gmail SMTP service:
config: host: smtp.gmail.com port: 465 secure: true secrets: user: <username> password: <password>
If you get an authentication error that indicates that you need to continue the sign-in process from a web browser when the action attempts to send email, you need to configure Gmail to allow less secure apps to access your account.
If two-step verification is enabled for your account, you must generate and use a unique App Password to send email from Kibana. See Sign in using App Passwords for more information.
Sending email from Outlook.comedit
Use the following email connector configuration to send email from the Outlook.com SMTP service:
config: host: smtp.office365.com port: 587 secure: false secrets: user: <email.address> password: <password>
When sending emails, you must provide a
from address, either as the default
in your connector configuration or as part of the email action in the rule.
You must use a unique App Password if two-step verification is enabled. See App passwords and two-step verification for more information.
Sending email from Amazon SES (Simple Email Service)edit
Use the following email connector configuration to send email from the Amazon Simple Email Service (SES) SMTP service:
Sending email from Microsoft Exchangeedit
Use the following email connector configuration to send email from Microsoft Exchange: