These instructions detail how to setup SNS Mobile Push for Amazon MessageBoard sample app.
-
Log in to the iOS Dev Center and Select "Certificates, Identifier & Profiles" from the right panel.

-
Fill the following details:
-
Select the MessageBoardSample app ID from the list. This will open up an accordion as shown below, click Edit to configure these settings.
- Scroll down and click the checkbox to enable Push Notifications
- Click Create Certificate under Development SSL Certificate Section.
- Follow the guide to create and uploaded your CSR file, click Generate to generate your certificate and then click "Download" to download .cer file to your local machine.
-
Double-click the .cer file to import it into your Keychain. Your keychain Access should be automatically opened.
- Select Certificates under the Category tab from the left panel.
- Find your certificate you just imported, the name should begin with "Apple Development iOS Push Servers…" and you should be able to expand the certificate to see a associated private key.
- Right-click the certificate,then choose Export "Apple Development iOS Push Services…", Keychain Access is smart enough to include your private key assoicated with this certificate.
- Save the exported p12 file, you may have to create a password before saving.
-
Log in to the AWS SNS Console in N.Virginia Region and Click "Add a New App" to create a new application.
-
Fill or Select the following details:
- Application Name: MessageBoardSample
- Push Platform: Apple Push Notification Service Sandbox (APNS_SANDBOX)
-
Choose the p12 file you exported from keychain in last step and enter the password you created when saving the file.
-
Click Load Credentials From File button, your certificates and private key fields should be automatically filled in below.
-
Select the application MessageBoardSample (APNS_SANDBOX) you just created in the left panel, and the
Application ARN
will be shown in Application Details Section, make note of it and you will need it in the following step.
It is assumed that you have already configured your Xcode project by following this README
-
Open the
MessageBoard/MessageBoard.xcodeproj
project file in Xcode. -
Open the
Constants.h
file and modify thePLATFORM_APPLICATION_ARN
definitions to the value shown on AWS SNS Console in previously step. -
Switch to project view and select the
Message Board
target. -
In the
Build Settings
tab, make sureCode Signing Identity
has been set to iOS Developer -
Run the app on the physical device (not simulator).
-
Tap SNS Mobile Push to navigate to Push Screen.
-
Tap Create Endpoint for The Device to add this device to your SNS endpoints list.
-
Enter some words in the push textfield and tap Push button.
-
An alert should pop up to indicate that a push notification has been received.