Files
calendar/packages/trpc/server/routers/viewer/apps/integrations.handler.ts
T
Benny JooandGitHub 9156848503 refactor: circular deps between app store and lib [2] (#23734)
* mv getDefaultLocations

* fix

* 2 more utils

* update imports

* fix

* move getConnectedApps

* move handlePaymentSuccess

* update imports

* fix import

* publish platform libraries
2025-09-10 23:18:59 -03:00

18 lines
544 B
TypeScript

import { getConnectedApps } from "@calcom/app-store/_utils/getConnectedApps";
import { prisma } from "@calcom/prisma";
import type { TrpcSessionUser } from "@calcom/trpc/server/types";
import type { TIntegrationsInputSchema } from "./integrations.schema";
type IntegrationsOptions = {
ctx: {
user: NonNullable<TrpcSessionUser>;
};
input: TIntegrationsInputSchema;
};
export const integrationsHandler = async ({ ctx, input }: IntegrationsOptions) => {
const user = ctx.user;
return getConnectedApps({ user, input, prisma });
};