Store push tokens #13

Closed
opened 2024-09-25 13:07:35 -04:00 by aCheeseInTheDark · 2 comments

Create a vapid key pair, update the server application key on the front end with the public key.
On the back end, store subscriptions submitted via /api/subscribe

The subscription should be updated with every page load and on change. Additionally, a cookie should be set with a user id to track whose subscription should be updated.

So, implies the need to finally use the database.

Create a vapid key pair, update the server application key on the front end with the public key. On the back end, store subscriptions submitted via /api/subscribe The subscription should be updated with every page load and on change. Additionally, a cookie should be set with a user id to track whose subscription should be updated. So, implies the need to finally use the database.
aCheeseInTheDark added this to the Tack Up Now project 2024-09-25 13:07:35 -04:00
Author
Owner

Ended up not using a cookie, had to use indexed db to store a subscription id.

Ended up not using a cookie, had to use indexed db to store a subscription id.
Author
Owner

Done. Future work should prevent subscriptions from being dropped if they aren't successfully submitted.

Done. Future work should prevent subscriptions from being dropped if they aren't successfully submitted.
Sign in to join this conversation.
No Label
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: aCheeseInTheDark/tack-up-now#13
No description provided.