The managed AuthKit setup in convex.json auto-provisions WORKOS_CLIENT_ID, WORKOS_API_KEY, and WORKOS_ENVIRONMENT_ID on preview deployments, but WORKOS_WEBHOOK_SECRET is not included. At runtime, the @convex-dev/workos-authkit
component fails because it can't find WORKOS_WEBHOOK_SECRET in the deployment's environment variables.
I'm passing WORKOS_WEBHOOK_SECRET as a build-time env var in my GitHub Actions workflow, but convex deploy doesn't have an --env-var-set flag, and convex env set doesn't support targeting preview deployments (only --prod or dev).
Is there a way to either:
- Have the managed AuthKit provisioning automatically set WORKOS_WEBHOOK_SECRET on preview deployments (similar to how it handles the other WorkOS env vars)?
- Target a preview deployment with convex env set from CI?
- Use project-level AuthKit environments so all deployments share the same webhook secret?
Using [email protected] and @convex-dev/[email protected].