Hello, everyone,
I want to build an invoice approval process. This process should pick up all incoming e-mails in a shared mailbox and then check the attachments to see whether the file name ends in PDF. If so, a file should be created in Sharepoint. If not, an email or teams message should be created ("failure report").
The problem is: For example, images in the sender's signature (company logo, advertising banner, etc.) are recognized by the Flow / Power automat as an attachment and so too often a "false report" is created. I only want a message if no PDF is attached directly as an attachment or if the PDF file is attached to an email attached to the email.
Scheme:
When a new email arrives in a shared mailbox [DEPRECATED] (Outlook)
->
Apply to each: Select an output from previous steps: "Attachments"
->
Condition: Attachments name ends with ".pdf"
-> If yes: Create file (Sharepoint)
-> If no: Post a message in a chat or channel (Teams), for example "Error message".
"Condition end"
->
Flag email (V2) Outlook: complete
->
Move email (V2) Outlook: Folder "done"
"End of Flow"
Can you help me? Thanks a lot!
Greeting from Germany
Philipp