How to use webhook with tRPC?

What endpoint should I set for the webhook? https://example.app/api/trpc/example ?
And how would I receive the req from the tRPC router?
More specifically, I'm trying to use Clerk's webhook.
Solution
my advise don’t use tRPC for this use a separate api endpoint e.g /api/webhook.

Otherwise if you really want to, create a router call webhooks, procedure called user.

then it would be /api/trpc/webhooks.user
Was this page helpful?