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

Function getActiveUsers

apps/api/src/controllers/insights.controller.ts:188–197  ·  view source on GitHub ↗
(
  req: FastifyRequest<{
    Params: { projectId?: string };
    Querystring: z.infer<typeof zActiveUsersQuery>;
  }>,
  reply: FastifyReply
)

Source from the content-addressed store, hash-verified

186});
187
188export async function getActiveUsers(
189 req: FastifyRequest<{
190 Params: { projectId?: string };
191 Querystring: z.infer<typeof zActiveUsersQuery>;
192 }>,
193 reply: FastifyReply
194) {
195 const projectId = await getProjectId(req as RequestWithProjectParam);
196 return reply.send(await getRollingActiveUsersCore({ projectId, days: req.query.days }));
197}
198
199// ---------------------------------------------------------------------------
200// Analytics — retention

Callers

nothing calls this directly

Calls 3

getProjectIdFunction · 0.70
sendMethod · 0.45

Tested by

no test coverage detected