Closed bluepuma77 closed 4 months ago
You need to generate a p8 file not a cert/pem file. And note that the p8 file used for the sandbox also works with production. Follow this guide https://developer.apple.com/documentation/usernotifications/establishing-a-token-based-connection-to-apns
@AndrewBarba Thanks! I tried to create a cert, but needed a key 😉
Sorry, I am a bit lost. Had
apns2
working with a.p8
file with sandbox, don't remember how I created that.Now I created a new cert with Apple ("Apple Push Notification service SSL (Sandbox & Production)", which generated a
.cer
file, which I can import into "Keychain access" and export as.p12
. But none of those seem to work withapns2
:Even converted
.p12
to a.pem
(which contains public and private key in text), still get error:Using
node:20-alpine
andapns2 11.7.0
.What am I missing?