We help IT Professionals succeed at work.

Powershell to trigger action when approval email?

janhoedt asked

I d like to sent a mail to a user via powershell, then when he/she replied with certain answer via mail, trigger another action. Iow, I send an automatically send mail from general mailbox "is your software Firefox 5.1 we deployed to your pc ok?" (that part already works). When user answers with YES (or voting buttons or other?), the software should be deployed to other users too via sccm (that deploying part also works).
How could I achieve that? Prefer not to use SharePoint online (since I do not manage it) but just powershell and mail.
Goal is to finally have 2 users approving software,  only then software is deployed.

Please advise.

Watch Question

IT Administrator
If you use Office 365 mailbox, you might consider using Microsoft Flow. It can monitor your or an any shared mailbox where it has an access and when approval mail comes it could execute some action (upload a script and run it on the SCCM server as an example).
If you like the idea start from the blog article UPLOAD AND RUN AN ON-PREMISES POWERSHELL SCRIPT FROM MICROSOFT FLOW