From f2eecb86cc1682e0497ddc388e305d76cfd0032c Mon Sep 17 00:00:00 2001 From: Matthew Raymer Date: Mon, 28 Aug 2023 19:58:40 +0800 Subject: [PATCH] Stubs for unsubscribe and mute --- src/main.ts | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/src/main.ts b/src/main.ts index a35b279..f532ce1 100644 --- a/src/main.ts +++ b/src/main.ts @@ -50,6 +50,20 @@ class Server { res.status(201).send(); }); + this.app.post('/unsubscribe', async (req: Request, res: Response) => { + const subscription = req.body as Subscription; + console.log(subscription); + + res.status(201).send(); + }); + + this.app.post('/mute', async (req: Request, res: Response) => { + const subscription = req.body as Subscription; + console.log(subscription); + + res.status(201).send(); + }); + this.app.get('/vapid', async (_: Request, res: Response) => { const vapidkeys: VapidKeys[] = await this.vapidService.getVapidKeys(); const vapidkey = vapidkeys[0];