Shopping for a hard to find item on Amazon.com that is always sold out? I was recently on the hunt for an external GPU enclosure that would show up in small quantities on Amazon. After failing to snag one by randomly checking periodically, I figured there must be a better way. Microsoft Flow to the rescue!
If you are not already familiar with Microsoft Flow, it is an easy to use automation tool that with a few clicks can create multi-step procedure that can run on a schedule or a trigger. In our case, we will create a custom flow that will check Amazon.com every 15 minutes, and if the item is in stock, it will send an e-mail notification. If you would like to learn more, check out this video:
To get started, let’s get setup with Microsoft Flow. Head over to flow.microsoft.com and hit Sign In. Then, sign in with a Microsoft Account. The first time you sign in you must choose your country and hit Accept.
For some silly reason, Microsoft does not let you create a custom flow without first adding a flow from a template. Just click on any flow on the welcome screen. I clicked the Add button under the Mobile item.
Now you can click on My flows on the top menu bar.
Click on Create from blank.
Click on Untitled next to Flow name to set a name.
Search for Schedule and then click on the Schedule icon followed by clicking on Schedule – Recurrence.
By default, the schedule recurrence task is set to 15 minutes. That is sufficient for our Amazon Stock Checker. Next, click on + New Step and then Add an action to add the second step.
Search for HTTP, click on the HTTP icon, select HTTP – HTTP. Next, set the “Method” field to Get and the “Uri” field to the URL of the item on Amazon you want to monitor.
Click + New step and select Add a condition. Set the “Object Name” field to Body located under the HTTP section. Set “Relationship” field set to contains and set the “Value” field to “Currently unavailable.” (remove the quotes, be sure to include the period).
We are now ready to setup the notifications. Under the “IF NO” column on the bottom right, click Add an action. Search for Notifications, click the Notifications icon, and then select Notifications – Send me an email notification. Type in the Subject and Body for the email you want to receive when the item becomes in stock.
Finally, scroll back up to the top and click Create Flow. Then click Done when it is saved.
If you want to turn the flow off, just click on My flows, and flip the switch off next to the one you created. Click the letter “i" to view the run history of the flow.
That’s it, I hope you enjoyed creating your first custom automation with Microsoft Flow.