I created a Amazon Pinpoint project using a production certificate from my Apple developer account, I configured my Xcode project with the project ID and APS environment equal to 'production', I upload the app to TestFlight and then install it in my device, when I send a message using the 'Test messaging' Amazon Pinpoint option (using an specific Endpoint Id or Device Token) the push notification is sent and received in my device, but when I launch a Campaign everything looks ok but I never received the push notification in my device, regardless that the segment I choose is dynamic and shows 1 eligible endpoint (I assume is mine because only I have installed this version).
Can anyone shed any light on this? Thanks in advance!
PD: In the development environment both works, the message to specific device and the campaign.
UPDATE: I've research in all Amazon pinpoint documentation and is unclear the solution and in other posts from AWS forums and stackoverflow I found that the solution is use the APNs Production certificate and I've already done this.
I found that this line of code in the function didFinishLaunchingWithOptions, the debug mode was always in true:
// Enabling app to receive push notification from Amazon Pinpoint
// Instantiate Pinpoint
let pinpointConfiguration = AWSPinpointConfiguration
.defaultPinpointConfiguration(launchOptions: launchOptions)
// Set debug mode to use APNS sandbox, make sure to toggle for your production app
pinpointConfiguration.debug = false
pinpoint = AWSPinpoint(configuration: pinpointConfiguration)
So the device could not be able to receive the remote notification from Amazon pinpoint
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.