Hi! My netlify functions are deployed and were working before. But now they are returning error 502 SyntaxError: Unexpected end of JSON input"," whenever I call POST method. It does save the data in Supabase database but doesnt return the JSON object.
Kindly guide me why it causing this issue?.
Thanks
Welcome to the forums and thank you so much for reaching out. Did you search the forums and see if any of the other solutions helped? Have you looked through this resource? It is a compilation of all of our build and deploy resources. This is a good starting point.
If you have worked through those guides and are still encountering issues please share the following information:
The error indicates that something is trying to consume some JSON, and is unable to do so because it is malformed.
While it may not be “you” directly, if it’s a function that you’ve deployed, then it’s still likely to be within your code, even if it were a function that was automatically deployed by a system that you’d just chosen to work with.
So if it’s what you see as the response given by a function that you’ve created yourself, you should debug the code of that particular function.