N
Novu•4w ago
Narek

Failed to generate token: secretOrPrivateKey must be an asymmetric key when using ES256

I have an iOS mobile application (https://apps.apple.com/us/app/ferienhausmiete/id6475052679) generated by PWABuilder. I setup Novu for sending push notifications via APNs provider. I am sending POST request to https://eu.api.novu.co/v1/events/trigger with PostMan and getting this response { "data": { "acknowledged": true, "status": "processed", "transactionId": "29861fe0-f8c5-4126-9f03-fc56e97e9eb4" } } but in Activity Feed page I have an Error (check the screenshot). I have double checked Key ID, Team ID, Bundle ID. With Private Key I made more checks. Private Key format is correct, I copy/paste it from AuthKey_XXX.p8 file (including -----BEGIN PRIVATE KEY----- and -----END PRIVATE KEY----- parts), I verified it with openssl ec -in AuthKey_XXX.p8 -text -noout command and the result was like this read EC key Private-Key: (256 bit) priv: XX:XX:XX... pub: XX:XX:XX... ASN1 OID: prime256v1 NIST CURVE: P-256 which means that everything is correct. On application side everything looks correct, after instalation I am asking for a permision to send notifications. Please help me to figure out with this problem. Let me know if you need more information/data to help me. Thanks in advance.
No description
4 Replies
Pawan Jain
Pawan Jain•4w ago
@Narek Thanks for sharing the details. I will look into this and will update
Narek
NarekOP•3w ago
Hi @Pawan Jain , had you chance to check my case, thanks in advance
Pawan Jain
Pawan Jain•3w ago
Hey Narek

I did check this from my end. APNS Integration credentials is correct. I have applied for apple developer account so that I can test the apns integration with my credentials. I will keep you updated
Narek
NarekOP•6d ago
Thank you very much @Pawan Jain Hi @Pawan Jain , have you some progress for this or maybe any suggestion how can I try some other way to fix this problem? I have tried to update the Private Key also via API requests, as I saw there was such problem a long times ago, but the result is same and I really stacked with this. With Android everything goes very smooth and I want to have the same result with iOS too 🙂 .

Did you find this page helpful?