Sending an Email

The Send an Email action enables you to generate and dispatch an email directly from a workflow. The content of this email can be dynamically populated using values from the following variables:

  • @urns
  • @results
  • @fields
  • @channel
  • @run.results.[results name].extra
  • @parent
  • @input

To illustrate a practical application, the following example shows how a healthcare facility might employ this action to notify staff via email that a new mother has been successfully registered.

In this case, @run.results.due_date calls upon the due date information that was captured during an earlier stage of the workflow.

Establishing an Email Notification System

This functionality also offers a highly efficient method for routing a contact’s query to a member of your team. Construct a simple workflow that collects the contact’s name, their specific question, and how they prefer to be contacted. Then, configure the action to send an email containing this data to your support desk or a Slack channel. This allows team members to immediately view the request through your CRM or Slack and provide a timely and appropriate response.

 

The variable @run.contact retrieves the contact’s name if it was obtained in a prior step. Simultaneously, @run.inquiry and @contact.channel reference the details of their inquiry and their chosen communication method (such as SMS, Call, or Email). It is important to note that if a value already exists for a contact’s “Name” field, you can opt to use @contact.name or @contact.first_name instead.

Configuring a Custom Sender Address

Emails are sent from a default Nyaruka support address. To utilize your own email address as the sender, go to the settings page within your account and select the email icon.

 

Here we’re using a Gmail-hosted email address. You’ll want to plugin your email address, host URL, credentials, port and encryption preference.

Special Configuration for Gmail

To successfully connect a Gmail address to your Textit account, you must enable the ‘Allow less secure apps’ option. This setting is located on the ‘Connected apps & sites’ page within your Gmail account security settings:

https://myaccount.google.com/security#connectedapps

Please be advised that a standard Gmail account is subject to a daily sending limit of 500 emails. Further details regarding Gmail’s sending restrictions can be found at this resource:

https://support.google.com/mail/answer/22839?hl=en

For additional questions, please contact us using the support widget located in the lower right corner of the screen.