omni_chat: consume receiver.flow and persist inbound telegram

This commit is contained in:
Ruslan Bakiev
2026-02-22 10:56:20 +07:00
parent 5679f22f7f
commit 2fd97f6593
6 changed files with 1467 additions and 8 deletions

View File

@@ -0,0 +1,16 @@
import { PrismaClient } from "@prisma/client";
declare global {
// eslint-disable-next-line no-var
var __omniChatPrisma: PrismaClient | undefined;
}
export const prisma =
globalThis.__omniChatPrisma ??
new PrismaClient({
log: ["error", "warn"],
});
if (process.env.NODE_ENV !== "production") {
globalThis.__omniChatPrisma = prisma;
}