feat(api): Add initial Push Notifications support

This commit is contained in:
Jesse Wierzbinski 2025-01-02 01:29:33 +01:00
parent acd2bcb469
commit d096ab830c
No known key found for this signature in database
21 changed files with 3301 additions and 3 deletions

View file

@ -0,0 +1,14 @@
CREATE TABLE "PushSubscriptions" (
"id" uuid PRIMARY KEY DEFAULT uuid_generate_v7() NOT NULL,
"endpoint" text NOT NULL,
"public_key" text NOT NULL,
"auth_secret" text NOT NULL,
"alerts" jsonb NOT NULL,
"policy" text NOT NULL,
"created_at" timestamp(3) DEFAULT now() NOT NULL,
"updated_at" timestamp(3) DEFAULT now() NOT NULL,
"tokenId" uuid NOT NULL,
CONSTRAINT "PushSubscriptions_tokenId_unique" UNIQUE("tokenId")
);
--> statement-breakpoint
ALTER TABLE "PushSubscriptions" ADD CONSTRAINT "PushSubscriptions_tokenId_Tokens_id_fk" FOREIGN KEY ("tokenId") REFERENCES "public"."Tokens"("id") ON DELETE cascade ON UPDATE cascade;

File diff suppressed because it is too large Load diff

View file

@ -281,6 +281,13 @@
"when": 1734555117380,
"tag": "0039_special_serpent_society",
"breakpoints": true
},
{
"idx": 40,
"version": "7",
"when": 1735776034097,
"tag": "0040_good_nocturne",
"breakpoints": true
}
]
}