MCPcopy Create free account
hub / github.com/Openpanel-dev/openpanel / liveRouter

Function liveRouter

apps/api/src/routes/live.router.ts:5–30  ·  view source on GitHub ↗
(fastify)

Source from the content-addressed store, hash-verified

3import type { FastifyPluginCallback } from 'fastify';
4
5const liveRouter: FastifyPluginCallback = async (fastify) => {
6 fastify.register(fastifyWS);
7
8 fastify.register(async (fastify) => {
9 fastify.get(
10 '/organization/:organizationId',
11 { websocket: true },
12 controller.wsOrganizationEvents,
13 );
14 fastify.get(
15 '/visitors/:projectId',
16 { websocket: true },
17 controller.wsVisitors,
18 );
19 fastify.get(
20 '/events/:projectId',
21 { websocket: true },
22 controller.wsProjectEvents,
23 );
24 fastify.get(
25 '/notifications/:projectId',
26 { websocket: true },
27 controller.wsProjectNotifications,
28 );
29 });
30};
31
32export default liveRouter;

Callers

nothing calls this directly

Calls 1

getMethod · 0.45

Tested by

no test coverage detected