Add proclamations api endpoint

This commit is contained in:
NeilClack
2026-03-18 01:09:21 -05:00
parent 791114d2aa
commit 56c688f674
17 changed files with 2044 additions and 126 deletions
@@ -0,0 +1,15 @@
-- CreateTable
CREATE TABLE "UserProclamations" (
"userId" TEXT NOT NULL,
"proclamationId" TEXT NOT NULL,
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
"updatedAt" TIMESTAMP(3) NOT NULL,
CONSTRAINT "UserProclamations_pkey" PRIMARY KEY ("userId","proclamationId")
);
-- AddForeignKey
ALTER TABLE "UserProclamations" ADD CONSTRAINT "UserProclamations_userId_fkey" FOREIGN KEY ("userId") REFERENCES "user"("id") ON DELETE RESTRICT ON UPDATE CASCADE;
-- AddForeignKey
ALTER TABLE "UserProclamations" ADD CONSTRAINT "UserProclamations_proclamationId_fkey" FOREIGN KEY ("proclamationId") REFERENCES "Proclamation"("id") ON DELETE RESTRICT ON UPDATE CASCADE;