Missing Clerk Token in Webhook Events Causing JWT Error in Supabase Integration #29424
Unanswered
rahul2008d
asked this question in
Questions
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have integrated Supabase with Clerk and set up webhooks for user events like user.created and user.updated. While other CRUD operations are functioning correctly with the Clerk token, I am encountering an issue during webhook events where the Clerk token is not being sent.
For existing users, everything works perfectly, and the token is received. However, during the webhook events, I receive the following error from Supabase:
This error seems to be related to the missing Clerk token during the webhook flow, despite the route being set up correctly. The issue only arises with webhook events, not with other operations.
Here is the relevant code snippet for creating the Supabase client:
route.js for webhook event capturing
In the webhook setup, I correctly verify the event and headers, but the missing Clerk token is causing the JWT error. Could you help investigate why the token is not being sent during webhook events and how to resolve this?
Here's the complete code for better context:
server action :
Beta Was this translation helpful? Give feedback.
All reactions