Move LiveKit Webhook route to app level
This commit is contained in:
parent
b0c7dcbc9a
commit
4e634dac54
@ -100,8 +100,6 @@ const createApp = () => {
|
||||
|
||||
appRouter.use('/health', (_req: Request, res: Response) => res.status(200).send('OK'));
|
||||
|
||||
// LiveKit Webhook route
|
||||
appRouter.use('/livekit/webhook', livekitWebhookRouter);
|
||||
// Serve OpenVidu Meet webcomponent bundle file
|
||||
appRouter.get('/v1/openvidu-meet.js', (_req: Request, res: Response) => res.sendFile(webcomponentBundlePath));
|
||||
// Serve OpenVidu Meet index.html file for all non-API routes (with dynamic base path injection)
|
||||
@ -113,6 +111,10 @@ const createApp = () => {
|
||||
res.status(404).json({ error: 'Path Not Found', message: 'API path not implemented' })
|
||||
);
|
||||
|
||||
// LiveKit Webhook route - mounted directly on app (not under base path)
|
||||
// This allows webhooks to always be received at /livekit/webhook regardless of base path configuration
|
||||
app.use('/livekit/webhook', livekitWebhookRouter);
|
||||
|
||||
// Mount all routes under the configured base path
|
||||
app.use(basePath, appRouter);
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user