T
tRPC

Clerk Webhook Input Undefined

Clerk Webhook Input Undefined

Iintiserx4/25/2023
Hi! I wrote a public procedure that takes in an input and updates user info based on Clerk Webhook. Clerk correctly pings the endpoint and the logic in the endpoint gets executed, but the input is undefined. I tried to ping the endpoint from postman with a request body. The request goes through but the input still says it's undefined.
Iintiserx4/25/2023
postman request
Nnlucas4/25/2023
Which adapter/integration are you using to run tRPC? Is it possible a middleware is messing with what arrives at tRPC? I've seen issues with common express middlewares being placed before the tRPC integration
Iintiserx4/25/2023
I'm using superjson as the transformer. And the project is from the t3-turbo-clerk template. All the other endpoints work perfectly as expected when called using useQuery from the frontend. The problem seems to be only happening when the request comes from an external source (the clerk webhook in this instance)
Iintiserx4/25/2023
Iintiserx4/26/2023
Fixed: I am new to trpc and didn't realize trpc endpoints aren't rest endpoints. Using trpc-openapi solved the issue
KHKevin Huang6/13/2023
Thanks for posting this. I'm running into the same issue right now. We are also using the t3-turbo-clerk template. In my case, I just trying to call an TRPC api endpoint directly without going through our Next.js frontend. I tried using Postman to call the TRPC endpoint and send data through request body, but the input param continue to be undefined like you mentioned. If I understood what you said above, does that mean whenever we make an external call to a TRPC endpoint, we need to use trpc-openapi?
Iintiserx6/14/2023
Yes you’re correct
KHKevin Huang6/14/2023
Gotcha. Thank you so much!

Looking for more? Join the community!

T
tRPC

Clerk Webhook Input Undefined

Join Server
Recommended Posts
Getting this error: Cannot read properties of undefined (reading 'upsert')I'm using the T3 Stack. And I'm fairly new to tRPC so I am not sure what this error is caused. I'm Stuck trying to utilize useQuery to fetch some data on form submissionI'm trying to call a procedure in trpc through the use of useQuery in react upon form submission. SocreateTRPCNext type errorHi everyone. So I started creating nextjs app with trpc + prisma set up. and when i use my AppRouterFull cache invalidation and timing problemI'm really enjoying using the full cache invalidation https://trpc.io/docs/reactjs/usecontext#invaliUsing Next.JS + FastifyMy node environment is Node 18, powered by PNPM. What's wrong: I have a few requirements for my appError Handling vs Error FormattingI'm a bit confused from the docs about how I should be handling errors on the server. The Error HandNext.js body-parsing issueA thead to discuss this issue: https://github.com/trpc/trpc/issues/4243Cannot find module '@trpc/react-query/server' or its corresponding type declarations```ts import { createServerSideHelpers } from '@trpc/react-query/server' ``` This should work, righProcedure with generic input?Is there a way to define a procedure so that it takes input with type parameters, and returns outputDelete item {0: {json:{id: 12324}}}When i try to mutate/delete item with id i am geting this payload `{0: {json:{id: 12324}}}`, withouQuery function depends on a variableIn tRPC v10 accessing a specific path is really easy, but because of that I don't control the query 'useInfiniteQuery' hook disappeared after moving to TurborepoI am using Turborepo with Next.js with the following layout, originally a T3 app - `/apps/app` - `/pconvert the result to date objectsI am not sure if this is even trpcs responsibility but I would like to get my date objects as date oECONNREFUSED with TRPC call on VercelAnyone run into this before? I just deployed my app to Vercel and I run into this error when I triggInvalid ValDoes TRPC string input have a limit? https://prnt.sc/KlXlyoGrzP8P Edit: It was actually from stripis possible to combine next-minimal-starter with react-router-dom ?Hi, I'm trying to combine https://github.com/trpc/trpc/tree/main/examples/next-minimal-starter and rusing same query for entries appHow to use same query for many components? I don't want to request api for many times ;-; I can't pHow can I make a direct fetch on a router endpoint from TRPC in NextJS on client?In the documentation you can use the vanilla TRPC client like this: ``` const bilbo = await clientHow to get unwrapped errors out of proxy clientI'm using sveltekit and in order to redirect from SSR you need to throw an error: https://kit.sveltCan you get the queryClient without using a hook?Can you get the queryClient without using a hook?