Push Notification iOS,There was an unexpected error delivering the notification.

Please provide the following:

  1. SDK Version: 41
    Expo cli: 4.5.2
  2. Platforms(Android/iOS/web/all): iOS
  3. Add the appropriate “Tag” based on what Expo library you have a question on.

I’m having issues sending push notifications to my device in Testflight as I get “There was an unexpected error delivering the notification. Try again.”.

Expo go and stand alone Android is working. Its a similar error to this post and used their solution with no luck: "There was an unexpected error delivering the notification" (iOS Push Notifications)

token: ExponentPushToken[MsSNPQO-xVV0Ig3eZfaZ-7]

Things I did:

  • Delete iOS Distribution certificate, Apple Push Services certificate, and provisioning profile from Apple Developer account
  • exp build:ios -c
  • Let Expo handle Distribution cert, APS, and provisioning profile

I’ve done this a few times and still no avail.

I’m having the same issue and did the same thing.
I’ve been trying to push from Expo Push Notification Tool and I get the same error :confused:

hi! there should be more error details if you inspect the ticket and receipt, which will give you a better indication of where to go next. Here are details on how to get the ticket and corresponding receipt

I don’t any more info on the Ticket response.
And I don’t have an ID to send a receipt request sadly.

Here is what I get exactly from the /push/send :

{
    "data": {
        "status": "error",
        "message": "There was an unexpected error delivering the notification. Try again.",
        "details": {
            "error": "ExpoError",
            "fault": "expo"
        }
    }
}

And here is my Request as well as my data :
image

{
    "to": "ExponentPushToken[TDdjYqInHPhQQGzb-9dlM4]",
    "data": {
        "notificationType": "NewMessage",
        "user_id": 3,
        "token_id": 11
    },
    "title": "Test",
    "body": "Hello",
    "channelId": "user_3"
}

To add more info I used expo credentials:manager to check my credentials.
All IDs match those I have in my Apple account.

One thing to note : I am not the Account Owner but I’m an Administrator.

Got the same response error as @voyelledev

I have a feeling it might have to do with the token. I’m getting the same push token id when I reinstall the app. I wonder why I’m not getting a different token. I notice this happening on iOS.

I made a same build under a different app using the same APN expo key and Distribution cert. I was able to get a push notification.

Do you mean you changed the bundle name ? Or just the provisioning profile ?

I have two apps that has the same code base with its own bundle identifier. So I’ll have two provisioning profile using the same distribution cert and same APN expo key. One app work and the other doesnt under the same iOS device. Hope that answers your question.

1 Like

It indeed seems to be linked to the token not changing on reinstall. I’ll try to change the experienceID the regenerate the Push Token and see if that works better.

I managed to get mine working now. My solution was to add another APN prod cert in the App ID configuration and run expo build:ios -c.
~Removing Provisioning Profile…Do you also want to revoke this Provisioning Profile on Apple Developer Portal? y
~Removing Distribution cert …Do you want to continue? n
~Removing Push Key… Do you want to continue? n

It will fetch the expo push key and distribution cert, and select let expo handle the provisioning profile.

@tirecoecomm What do you mean by adding another APN Prod cert ?
Do you mean here ? I thought that you didn’t need to use that ?

Update: it looks like this could be a server-side issue on our end. We’re investigating it now and will update here once we know more

Thank you for the feedback.
Is it an issue occuring for the certificates generation or for the notifications ?

If needed here is a token that doesn’t work : ExponentPushToken[TDdjYqInHPhQQGzb-9dlM4]

Would be neat though to have a more explicit error message :confused:

The issue we’ve identified does not have to do with certificates. We’ve identified the problem and will be pushing out a fix shortly!

2 Likes

Great. Thanks @charliecruzan. I will stop trying to clear my credentials for now then in hope the push fixes my issues.

Fix has been deployed! Let me know if you still see the same issue

3 Likes

It works ! Thanks @charliecruzan