doc
trpc + fastify POST request not working
I have a trpc mutation like this:
I am trying to call it via HTTP:
it errors with:
"code": -32600, "data": { "code": "BAD_REQUEST", "httpStatus": 400, .....}Not sure whats going on or why is it erroring. Any help is appreciated 🙂
3 replies
TRPCClientError: Unexpected end of JSON input
Hey I am running into this issue when calling a
mutateAsync
in production in Vercel (the error does not appear in localhost dev mode).
TRPCClientError: Unexpected end of JSON inputMy code base is so large that I am not sure where do I start to debug. Are there any best practices that I should follow to avoid this error? It is similar to this issue: https://github.com/trpc/trpc/discussions/1847#discussioncomment-4244990
19 replies