0

I use the same email template for more than one alert or process. Is it possible to capture the id or name of the triggering Flow, workflow rule, or process definition in the email message? This would help trouble shooting. Thanks

1 Answer 1

0

Given that the email body includes some reference to the target object (a Case, an Opportunity, etc.) ...

Historically, what I would do is have the Process Builder or Flow write a Task under the email alert's target object with:

  • Subject: Myprocess/MyFlow initiated email
  • Status: Completed
  • OwnerId: Running user's Id
  • DueDate: TODAY()

There's no runtime context for the Email Message beyond the available merge fields such as $User, $Profile, etc.

An alternative would be for the Flow or Process Builder to update a field in the target object (Last_Used_Automation__c) that is referenced as a merge field in the email message.

  • I'd avoid this due to slower processing (extra DML and in some case, the recursive Save process)

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.