Page 167 - Programming the Photon Getting Started With the Internet of Things
P. 167
Figure 8.8 Gmail actions.
In the body of the e-mail you can include certain variables that are not filtered as plain
text; they are as follows:
CreatedAt The date and time that the e-mail was created and sent
DeviceName The device name of the Photon board that you provided
Value The actual value of the variable when it was triggered
Variable The name of the variable that we are reading; in this case it is analogValue
Once you have filled in all the required fields, click Create Action to go to the final
step of the recipe. Here you will click Create And Activate, which will create the recipe
and have it go live on the IFTTT Web service. The live recipe will then check the Photon
every 15 minutes—this makes sure you do not get flooded with e-mails every second and
balances out the server load.
Try placing the sensor in a bright environment to test the IFTTT recipe you created.
After about 15 minutes you should receive an e-mail like that shown in Figure 8.9 with all
the details that you filled out in the e-mail actions section.