function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Stuart GrimshawStuart Grimshaw 

Is there a way to attach files to outgoing workflow email alerts?

As part of an approval process I'm creating I'd like to be able to attach a license key to an email that is then sent to a contact email of an opportunity when the opportunity is approved.

We have a separate system that generates & stores our license keys & I'd like to avoid having to upload the key to SFDC to avoid duplication & confusion over which is the valid key as the attached one will have a short expirey time on it.
Best Answer chosen by Stuart Grimshaw
sfdcfoxsfdcfox
Unfortunately, you would not be able to accomplish your goal with this method. Instead, you'll need to create a trigger on the license object that fires an asynchronous callout after the record is approved, and have that callout query your external system for the key and send the email.