Notification rejected by the APNs gateway: Optional[InvalidProviderToken] #915
Replies: 3 comments 3 replies
-
Respectfully, issues like these get opened from time to time and they invariably get closed with something like "I accidentally switched the key ID and team ID." I'm happy to help, but strongly, strongly suspect this isn't a bug that we can fix with a change to Pushy itself. With that in mind, I'm going to convert this to a discussion. |
Beta Was this translation helpful? Give feedback.
-
One thing I'm noticing is that you appear to be passing in the payload builder instead of the payload itself (perhaps you're calling Beyond that, I'm assuming that you've changed the topic from your actual topic to |
Beta Was this translation helpful? Give feedback.
-
Hi, Instead of .toString(). I changed to below format final ApnsPayloadBuilder payloadBuilder = new SimpleApnsPayloadBuilder(); FAILURESimplePushNotificationResponse{pushNotification=SimpleApnsPushNotification{token='6ff6319f5a6d5eff6b2db0df9d88075799c88a90ec2b60caef12c309e4c86b5a', payload='{"aps":{"alert":{"body":"Example!"}}}', invalidationTime=2021-09-08T07:44:20.888Z, priority=IMMEDIATE, pushType=null, topic='com.sample.PushAPN', collapseId='null', apnsId=null}, success=false, apnsId=dbc5e598-6138-562c-5707-89d3f6016afe, rejectionReason='InvalidProviderToken', tokenExpirationTimestamp=null} I am able to send PN using cert file. the same way code i am using for Payload builder there it is working. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
I am able to send Push Notification with the same KeyId,TeamId and .p8 file from PN tester. Running the java code for PN i am getting the response as Notification rejected by the APNs gateway: Optional[InvalidProviderToken]
Beta Was this translation helpful? Give feedback.
All reactions