How to access email attachment using Lightning clients:availableForMailAppAppPage?

I can access people, emails addresses, message body from the interface clients:availableForMailAppAppPage in lightning component.

Not able to find documentation on how to access attachments. I did try v.attachment and v.attachments ( assuming it logical like v.people) but no use! Any help please?

Answer

Thanks for your post.

Attachments are not currently a part of the data structure that returns the Outlook context the user has selected. That’s why you cannot access them, unlike email addresses, subject, body etc.

It seems like that would be useful, and I would suggest making a post on the Salesforce IdeaExchange to that affect to get the teams aware of it. (https://success.salesforce.com/ideaSearch)

If you’re ok being reliant on the end user saving the attachments, you could gain access to the SFDC content documents that are saved by searching for the subject in the tasks, and then use that record to find the related ContentDocuments that are available.

Thanks,
Carol John
(Tech. Writer at Salesforce)

Attribution
Source : Link , Question Author : Manju , Answer Author : Carol John

Leave a Comment