How can I get the newest file to be attached to the Logic Apps Send Email (Outlook) email body? For example, there was a workflow on my Azure Function that stores the file into Azure blob storage the file will append based on date information on the name of the file, and then this Send Email will attach the file into the body email.
CodePudding user response:
Based on the above shared requirement, we have created a sample workflow in our local environment.
In our workflow we have hardcoded the blobname
using the compose action, post that we are checking whether that particular blob is present in the storage account or not.
If the blob is present in the storage account it will pull the content of the blob & it will trigger an email(used Send an email action
to sent email) by appending the content of that blob as an attachment to that email.
Here is the logic app screenshot:
Here is the output screenshot:
Note:
In our workflow, we have hardcoded the name of the blob. In your case, you need fetch the blobname
from the function app output.