Automated Deployment - IoT Channel Using Amazon Pinpoint

Automated Deployment

Before you launch the automated deployment, please review the architecture and other considerations discussed in this guide. Follow the step-by-step instructions in this section to configure and deploy IoT Channel Using Amazon Pinpoint into your account.

Time to deploy: Approximately five minutes

What We'll Cover

The procedure for deploying this architecture on AWS consists of the following steps. For detailed instructions, follow the links for each step.

Step 1. Launch the Stack

  • Launch the AWS CloudFormation template into your AWS account.

  • Enter values for required parameter: Stack Name.

  • Review the other template parameters, and adjust if necessary.

Step 2. Enable an Amazon Pinpoint SMS Channel

  • Configure an Amazon Pinpoint project in which the SMS channel is enabled.

Step 3. Upload the IoT Segment

  • Create the segment to send messages to.

Step 4. Send a Test Message (Optional)

  • Send a test message to Amazon Pinpoint and verify the message is received in AWS IoT Core.

Step 1. Launch the Stack

This automated AWS CloudFormation template deploys IoT Channel Using Amazon Pinpoint in the AWS Cloud.

Note

You are responsible for the cost of the AWS services used while running this solution. See the Cost section for more details. For full details, see the pricing webpage for each AWS service you will be using in this solution.

  1. Sign in to the AWS Management Console and click the button below to launch the iot-channel-using-amazon-pinpoint AWS CloudFormation template.

    
                                IoT Channel Using Amazon Pinpoint launch button

    You can also download the template as a starting point for your own implementation.

  2. The template is launched in the US East (N. Virginia) Region by default. To launch this solution in a different AWS Region, use the region selector in the console navigation bar.

    Note

    This solution uses Amazon Pinpoint, which is currently available in specific AWS Regions only. Therefore, you must launch this solution in an AWS Region where Amazon Pinpoint is available. For the most current service availability by region, see the AWS service offerings by region.

  3. On the Create stack page, verify that the correct template URL shows in the Amazon S3 URL text box and choose Next.

  4. On the Specify stack details page, assign a name to your solution stack.

  5. Under Parameters, review the parameter for the template and modify it as necessary. This solution uses the following default value.

    Parameter Default Description
    IoT Topic Name campaign/pinpoint

    The IoT messaging topic name that Amazon Pinpoint will use to send messages

  6. Choose Next.

  7. On the Configure stack options page, Choose Next.

  8. On the Review page, review and confirm the settings. Be sure to check the box acknowledging that the template will create AWS Identity and Access Management (IAM) resources.

  9. Choose Create stack to deploy the stack.

    You can view the status of the stack in the AWS CloudFormation console in the Status column. You should see a status of CREATE_COMPLETE in approximately five minutes.

Note

In addition to the primary AWS Lambda function pinpoint-iot-campaign-hook, this solution includes the CustomResourceHelper Lambda function, which runs only during initial configuration or when resources are updated or deleted.

When running this solution, the CustomResourceHelper Lambda function is inactive. However, do not delete this function as it is necessary to manage associated resources.

Step 2. Enable an Amazon Pinpoint SMS Channel

Use this procedure to configure an Amazon Pinpoint project in which the SMS channel is enabled.

  1. Navigate to the Amazon Pinpoint console.

  2. In the All projects list, select IoT Application.

  3. In the navigation pane, select Settings, SMS and voice.

  4. Select Edit (on the upper-right corner of the SMS settings card).

  5. On the Edit SMS page, select Enable the SMS channel for this project.

  6. Select Save changes.

Step 3. Upload the IoT Segment

Use this procedure to create the segment to send messages to.

  1. Download the IoTSegment.csv file.

  2. In the navigation pane, select Segments.

  3. Choose Create a segment.

  4. Select Import a segment.

  5. Select Choose files, navigate to the IoTSegment.csv file on your local machine, and select Open.

  6. Select Create segment.

Step 4. Send a Test Message (Optional)

Use this procedure to send a test message to Amazon Pinpoint and verify the message is received in AWS IoT Core.

  1. Navigate to the AWS IoT console.

  2. In the navigation pane, select Test.

  3. Under Subscribe, enter the topic name you specified in the IoT Topic Name AWS CloudFormation template parameter. The default value is campaign/pinpoint.

  4. Select Subscribe to topic.

  5. Open a new browser tab and navigate to the Amazon Pinpoint console.

  6. In the All projects list, select IoT Application.

  7. In the navigation pane, select Campaigns.

  8. Choose Create a campaign.

  9. Create a campaign with the following fields:

    • For Campaign name, enter a campaign name.

    • For Campaign type, select Standard campaign.

    • For Choose a channel for this campaign, select SMS.

  10. On the Choose a segment page, under Segment, select IoTSegment.

  11. Choose Next.

  12. On the Create your message page, in the Message text box, enter a test message.

  13. Choose Next.

  14. On the Choose when to send the campaign page, choose Next

  15. On the Review and launch page, review and confirm the settings. Then, select Launch campaign.

  16. In the browser tab with the AWS IoT console, verify that your test message is displayed.