Lambert
Lambert
TtRPC
Created by Lambert on 3/19/2025 in #❓-help
NextJs trpcClient and merged router. But it is returning a html doc instead of json error.
I am new trpc, I am implementing a single trpcClient and merged router, in nextJs v15, app router. When i implement trpc with api routes /api/v2/user/[user]/route.ts and utils/trpc nexbacthlink /api/v2/user. this code snippet is working fine. I encountered an error, when change the routes to /api/v2/route.ts and utils/trpc nexbacthlink to /api/v2. the request to server /api/v2/updateUserStatus is 200 but it's returning a Not Found Page in next js instead of a json. Does anyone know how to fix this issue?
4 replies