Error with push notifications { "status":"error }

Hi expo team, can you help us with an issue we are having with push notifications? Not sure what to debug because the receipt is just an object with status: error. Please see log below:

Error sending message {"sound":"default","title":"REDACTED:","body":"REDACTED ","to":"ExponentPushToken[REDACTED]"} with receipt {"status":"error"}

This is with our standalone app which is released on iOS and Android.

thanks!

We often include some more debug info in the error payload – what does the bare HTTP response say?

We aren’t currently logging that, will add that right now and get back to you.

Hey @ide, I work with Mike :slight_smile:
Any tips for how to get the bare HTTP response using expo-server-sdk? Its API only exposes ExpoPushReceipts as far as I can tell.
(Default option is we’ll write our own code to hit the endpoint, but of course we’d prefer to stick with the Expo SDK.)

Thanks!

The easiest way would be to console.log or set a breakpoint in the npm package where the response arrives.

I’m getting this, too, when I run a push request through Postman or CURL:

<html>
    <head>
        <title>502 Bad Gateway</title>
    </head>
    <body bgcolor="white">
        <center>
            <h1>502 Bad Gateway</h1>
        </center>
        <hr>
        <center>nginx/1.11.3</center>
    </body>
</html>

@llamaluvr Are you seeing {"status":"error"} and a 200? It seems like you’re getting back a 502 error instead, which might have a different cause.

Getting 200’s/ status = OK now.

There was a moment where if I added --max-time 900 to the curl request it would go through right away, but if I didn’t, it would hang for a while (the long hang would end in a 502).