> For the complete documentation index, see [llms.txt](https://docs.work-relay.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.work-relay.com/automations/global-actions-and-action-groups/types/send-email.md).

# Send Email

### Generic Global Action properties

This action has generic properties, as other global actions:

* **Name** - give Action a name in order to search for it easy, otherwise system will use ID of this Action.
* **Type** (Rule or Action) - this is mandatory. Select "Action".
* **ID** - given by system after saving a new Action first time.
* **Status** - you can activate or deactivate an action temporary (e.g., for debug).
* **Context Object Type** - a data source which fields can be used in Action [conditions](/automations/queries-and-conditions/working-with-conditions/conditions-overview.md) and properties.
* **Action Type** - main property which determines what Action will do and it's configuration. [Explore all action types here](/automations/global-actions-and-action-groups/types.md).
* **Execute** - specify if Action will be executed always or when some conditions are matched.&#x20;

<figure><img src="/files/Wyr0epEhpQbqgP9w7cC9" alt=""><figcaption></figcaption></figure>

### Overview

This type of Action allows to send an email in different formats.

* Add an action with the **Action Type** = Send Email. See more info about creating Actions in [Working with actions](/automations/global-actions-and-action-groups/basics/working-with-actions.md#how-to-create-an-action) article.
* Select users to send emails **to**.
* Specify "**CC**" field value, if needed. Here you can add static email address, use Merge fields and Formulas.
* Specify "**From**" field, if necessary.&#x20;

{% hint style="info" %}
By default user will get email from current user email address. If you specify "**From**", user will get email from current user email address, but the label will be shown as specified in "**From**".&#x20;

If the Organization has "Organization-wide email address" specified, you can insert it's name in the "**From**" field and it will be displayed to the recipient as "from" address.
{% endhint %}

* Populate mandatory "**Subject**" field.
* Select email **Type**. See below about types.
* Specify **Attachments**, if necessary. See below.

<figure><img src="/files/ipBfMolU6gUZK87RE9Nk" alt=""><figcaption></figcaption></figure>

You can send email to selected Users, Contacts, Leads, all users inside selected Profiles, Roles, Groups or you can set custom recipient using Advanced mode.

If switch to Advanced mode, the "To" field will switch to text input mode, and selected users will be shown as their Salesforce IDs. In this mode user is able to populate "To" field with merge fields or formula returning ID or list of IDs. These IDs must be valid IDs of Salesforce users.

<figure><img src="/files/qxpSixQnS23Y5KVke3Ip" alt=""><figcaption></figcaption></figure>

* **Execute in background:** select it if you need to execute this action in other context than current user operation. See more info at [How to use "Execute in Background" feature](/automations/global-actions-and-action-groups/using-actions/how-to-use-execute-in-background-feature.md). If check this option, the new field will appear:
* **With gap**: by default it is 0, but can be set as an integer number of minutes. This field specifies interval before action execution.

<figure><img src="/files/sBwRNaTkFjO5L7i8z0Wr" alt=""><figcaption></figcaption></figure>

### Email types

* **Plain Text**\
  Email type using a very basic character set and contains no formatting or images. The email message should be typed in the main text area under "Attachments".<br>
* **HTML** **Text**&#x20;

  Email type supporting HTML to provide formatting and semantic markup capabilities in email that are not available with plain text. The email message should be typed in the main text area as HTML code. \
  \
  If HTML is selected, a "Preview" button will be shown. Click it to see popup that will show how HTML code entered will be shown in browser.

{% hint style="warning" %}
Pay attention:

It is no unified standard of rendering emails and supporting HTML/CSS properties. Each email service and application can show the same email differently. Please study email layouting basics before.
{% endhint %}

<figure><img src="/files/2AVdwlHnKktjGl3Woeao" alt=""><figcaption></figcaption></figure>

* **Email Template**&#x20;

  User is to choose existing email template from the list.\
  \
  If select this type, you must select Email Template. Note that to be able to use standard email templates, you should provide "[Email delivery contact](/administration/setup/complete-overview-of-setup.md#specify-email-contact)" on the Notification Settings Tab.\
  \
  Optionally, specify the Source ID. It is an ID of the record of Data Source Object, which data will be used in Email Template merge fields (if any). If not specify (by default) it will be an ID of the current Action.<br>

<figure><img src="/files/ds3NcrztdLAjynPdQxsi" alt=""><figcaption></figcaption></figure>

### Adding attachments

This option is available only if Email type = Plain Text or HTML Text:

![](/files/4cbbc34e5baa8d0abda7249e4cb32c577f5ccb15)

* Add as many attachments as necessary.
* Select Record or Process in the "Type" field.
* Enter File IDs or Names if you have source record specified. All files with matching names attached to the source record will be sent as attachment. For IDs you should specify [Content Version](https://help.salesforce.com/s/articleView?id=experience.content_revise.htm\&type=5) IDs.
* If you select a Process in the "Type", all files with matching names attached to the step, which action has been executed at, will be sent as attachment.

{% hint style="info" %}
File names can be used only when you have source record specified. Otherwise use IDs.
{% endhint %}
