How to set up an Email Alert whenever a new record is created by e2a?
Setup an Email Alert whenever a new record is created by e2a
Whenever an e2a email is received and it creates a new record (Standard/Custom Object) as per the e2a Email Rule criteria, it is often useful to send an email notification when it is created. This notification email could be sent to record owner, any specific user or an external email address. If you want to setup such alert system so that an email alert is sent whenever a new record is created by e2a, then please proceed as follows. The steps below explain the procedure for setting email alerts on 'Lead', but could be used for any other Object (Standard i.e. Case / Custom), by just replacing 'Lead' with that object.
First, we need to create a new custom field in 'Lead', which will be used to indicate the arrival of new email on 'Lead record.
- Go to Setup | Lead | Fields
- Select New in section Lead Custom Fields & Relationships
- Select Picklist and click Next
- Provide Field Label and Select Enter values for the picklist, with each value separated by a new line (Example Field Label: 'New e2a Email'). A checkbox can also be used instead of picklist.
- Set values of Picklist as No and Yes, each in separate line
- Check Use first value as default value ( 'No' will be default value in this case)
- Provide Description and click Next (Example Description: 'The field is set to 'Yes' when an e2a email arrives and creates a new record')
- Select appropriate profiles in Establish field-level security and click Next
- Select appropriate page layouts in Add to page layouts and click Next (There is no requirement for this field to be visible on any layout and can thus be kept hidden)
Secondly, we need to configure a Field Assignment Rule in the related 'e2a Email Rule' to populate the created picklist (New e2a Email) on arrival of an e2a email.
- Go to e2a Email Rules and select your email rule linked to Target Object Lead. Click on the e2a email rule
- Click on the New button in the Field Assignment Rule section
- Select Create Record from the Trigger On drop-down
- Select 'Always' from the Trigger Type drop-down
- Enter a number ( greater than 0) in the Processing Order field
- Select 'Fixed Value Assignment' from the Assignment Type drop-down
- Select 'New e2a Email' (picklist created earlier) from the Select Field drop-down
- Enter 'Yes' in the Field Value field ( To populate the picklist 'New e2a Email ' whenever a new e2a email is received)
- Click on Save
Thirdly, we need to create an Email Alert that will be sent out to the record owner/email address whenever a new record is created.
- Go to Setup | Create | Workflow & Approvals| Email Alerts and click New Email Alert
- Add Description, select Lead for the Object drop-down, and select Email Template (This template will be used for Email Alerts)
- Select User from Search in Recipient Type (To whom Email Alerts will be sent)
- Select User in Available Recipients and click on Add button to move it to Selected Recipients
- You can enter up to five email addresses in Additional Emails to be notified
- You can choose default From Email Address from the drop-down list. Click on Save button
Now, to send an Email alert, either a Process or workflow could be created. Below, both the methods are described to be used as per your need.
Method 1: Configure Using Process Builder
- Go to setup and search for Process Builder
- Setup | Create | Workflow & Approvals| Process Builder
- Select New, enter Process Name and Description for the Process
- Set The Process starts when drop-down to A record changes
- Click Save
- Choose the Target object which starts the Process
- Select Lead from the object drop down
- Select when a record is created or edited option for what starts the Process
- Click Save
- Add the Criteria for this Process
- Enter Criteria Name
- Select Conditions are met option for Criteria for Executing Actions
- To set conditions, set Field to your custom created picklist, set Operator to equals, Type to String, and Value to Yes
- Select All of the conditions are met (AND) option for Conditions
- Click Save
- Add Immediate Action to execute when the above-set criteria evaluate to True
- Click on + Add Action
- Select Email Alerts for the Action Type drop-down
- Add an Action Name
- Select the Email Alert created on Lead object
- Click Save
- Activate the Process
Method 2: Configure Using Workflow Rules
- Go to setup and search for Workflow Rules
- Setup | Create | Workflow & Approvals| Workflow Rules
- Select New and click Next
- Select Lead from drop-down object list and click Next
- Configure the Workflow by providing the Rule Name
- Select Created for Evaluation Criteria
- For Rule Criteria, select Criteria are met
- Set Field to your custom created picklist
- Operator to equals
- Value as Yes
- Click Save and Next
- Select Select Existing Actions from Add Workflow Action
- Select Email Alert from the Search drop-down and click on Find button
- Select the created Email Alert and click on Add
button
- Click on Save
- Click on Done and Activate on next page above Workflow Rule Details to activate newly created Workflow Rule
Please contact us at support@ortooapps.com for any questions.
★★★★★ - EXCELLENT
★★★★☆ - GOOD
★★★☆☆ - OK
★★☆☆☆ - POOR
★☆☆☆☆ - RUBBISH