How do I notify a lead owner by email when a lead is assigned to them?

You can create email notifications using the Routines feature. Routines is the fastest way of creating email notifications. It doesn't require any Groovy scripting, and automatically appends a link to the lead in the email.

The following steps apply mainly to Redwood User Experience (UX) users. However, Simplified UI users can also use these steps but note that some options on the Trigger page aren't available for Simplified UI users.

  1. Open Application Composer outside a sandbox (Navigator > Configuration > Application Composer).
  2. Click Routines.
  3. Click Create Routine.
  4. Click Skip Templates.
  5. Enter a name and description. For example: Email Notification for New Lead Owner Notify owner that a lead was assigned to them.
  6. Select the object, in this case Sales Lead.
  7. Click Next.
  8. On the Trigger page:
    • Redwood UX users have the following options:
      • Hourly

      • Daily

      • Weekly

      • Monthly

      • Yearly

      • Record created

      • Record deleted

      • Attribute changed

    • Simplified UI users have the following options:
      • Hourly

      • Daily

      • Weekly

      • Monthly

      • Yearly

    Note: For Simplified users, if the existing options don't suit your requirements, you can use Rules to specify a trigger when the routine should run. For example, you can create and apply certain rule conditions to Attribute Owner ID, or Last Update Date, or Status and so on to trigger and submit the routine.
  9. For Redwood UX users, select Attribute changed and then select Owner ID from the list of attributes because you're sending the email after the owner is updated in the record.
    Note: Redwood User Experience (UX) users will have access to more triggers to specify when the routine runs. For example, in addition to the defined recurring schedules, they can choose to run the routine as soon as an attribute is changed or when a record is created, updated, or deleted.
  10. Click Next.
  11. On the Actions page, select Send Email as the action type.
  12. In the To field, select Owner ID.
  13. In the Subject and Body fields, you can enter both text and mail-merge attributes. For example, to include the lead name, enter Name in the Attribute search box, press Return, and click Lead Name. Your action enters the mail-merge field {{$Name}}.
    Note: The email sent to the new owner gets automatically appended with a link to open the lead.
  14. Optionally, you can add another action. For example, in addition to sending the email you can create a task by selecting Create Task from the Action Type list and entering the task attributes.
  15. Click Next.
  16. In the Rules, page you can create rules and groups of rules that select the leads the notification runs on. In this example, we're notifying the owner when any lead is assigned to them, so you can skip this step.
  17. Click Next.
  18. On the Review page, review your entries and click Submit.

See Overview of Routines for more information about routines.