AWS IoT Button Integration in 10 minutes

  • Create a Lambda Function
  • Define a Message
  • Write a Rule

In this article, we presume 

  • You have a AWS IoT Button configured using your mobile app
  • You have registered with Boodskap Platform 

Create AWS Lambda Function

Login to your Amazon AWS Console and select Lambda service.

  • Click Create Function
    • Name: boodskap-iot-button
    • Runtime: Node.js 8.10 or above
    • Existing Role: lambda_basic_execution
  • Upload the function code
  • Function code has three type of handlers implemented, pick your choice of handler
    • Make sure you enter one of the below in the Handler field
      • httpimpl.handler (for HTTP communication)
      • mqttimp.handler (for MQTT communication)
      • udpimpl.handler (for UDP communication) 
  • Define Environment Variables
      • Your Boodskap domain key
    • API_KEY
      • Your Boodskap API key
      • Your defined message id, (will see in next section)

Defining Boodskap Message

  • Login to the platform
  • Go to Message Definitions
    • Click Define Message and follow the below screen shot. You could use any message ID
      • Below two fields are mandatory
        • click : INTEGER
        • battery: VARCHAR

Configure AWS IoT Button

  • In the Aws IoT Button Dev mobile application
    • Choose the button
    • Choose the Lambda Icon
    • In the Use Existing Lambda Functions tab
    • Pick boodskap-iot-button and press Change Action

Platform will start receiving single and double click events. You could use the Rules Engine module to further process the data


No comments yet. Why don’t you start the discussion?

Leave a Reply

Your email address will not be published. Required fields are marked *