This howto's purpose is to connect the AWS IoT Button from Amazon to IFTTT's Maker Channel. This was spawned out of my want to toggle my Philips Hue Lights on and off with the buttons.
I assume that you have a working knowledge of IFTTT but, like me, have some kind of non-computer science degree when it comes to AWS and Java. So it is written for the most basic of folks to follow along.
There will be 4 main sections, Preperation, IFTTT, AWS Lambda, AWS IoT.Preperation
1. Complete "Getting Started" section: https://aws.amazon.com/iot/button. This includes following the tutorial to send youself e-mails using SNS. (This will connect your device to the internet and allow it to communicate with AWS Services).
2. Once you have sent yourself an e-mail by clicking your AWS IoT Button you are ready to continue.IFTTT
1. Login to your IFTTT account and "connect" the Maker Channel/Applet ( https://ifttt.com/maker ) Once "connected", take note of the key under which is the X's in: "URL: https://maker.ifttt.com/use/XXXXXXXXXXXXXXXX" (edit: 03/09/17)
2. Next create 3 recipes of your liking to be triggered from the Maker Channel as the "If". When prompted for "Event Name" place the following text: SINGLE for one channel, DOUBLE for another, and LONG for the last. (we will be using the Phillips Hue Channel as the "That" part of this IFTTT).
Note: The recipes labeled, "SINGLE" "DOUBLE" "LONG" are triggered by single, double or >1.5s pressing the button on the AWS IoT Button.AWS Lambda
1. Navigate to: https://console.aws.amazon.com/lambda
2. Select "Create a Lambda function"
3. Skip Step 1: Select blueprint (This is at bottom of page)
4. Name your function anything you want, if you purcahsed multiple buttons, name the button purposefully.
5. Under Description I placed "IFTTT Maker Channel 1st Attempt", but this is not important.
6. Ensure the "Runetime*" is Node.js 4.3
7. Copy the code provided below and paste into inline code editor.
8. Delete "[your private key here]"
9. Insert the noted "Your Key is:" from the IFTTT step 1. ensure that you remove the [ ] but keep the '
10. Leave Handler is index.handler. Under role select * Basic execution role. It will open a new Tab. Simply select allow.
11. Select save. On next screen select create function.AWS IoT
1. Navigate to https://console.aws.amazon.com/iot
2. You will see 4 blue boxes each with an unique icon in the lower left corner. These boxes represent either a Thing (the Robot Hand), a Rule (3 small boxes), a Certificate (the Paper), or a Policy (the Handshake). Select the Rule Box.
3. A menu will appear on the right hand side of the browser window. Select the header "Edit Actions"
4. Select "Lambda Action"
5. Select "Function name [somethinng]"
6. Under the drop down menu, select the name you created in AWS Lambda Step 5.
7. Select "Update"
THAT, my friend, IS THAT! If you have any questions please leave a comment!