From 12f8614f6b085050b4a3d7f7bda6aba532f862f0 Mon Sep 17 00:00:00 2001 From: Kit La Touche Date: Sun, 3 Aug 2025 21:23:46 -0400 Subject: Add preliminary documentation on web push events --- docs/developer/book.toml | 2 +- docs/developer/server/push-notifications.md | 24 ++++++++++++++++++++++++ 2 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 docs/developer/server/push-notifications.md (limited to 'docs') diff --git a/docs/developer/book.toml b/docs/developer/book.toml index ef1296c..d8e8b1d 100644 --- a/docs/developer/book.toml +++ b/docs/developer/book.toml @@ -1,6 +1,6 @@ [book] title = "Pilcrow for Developers" -authors = ["Owen Jacobson"] +authors = ["Owen Jacobson", "Kit La Touche"] language = "en" multilingual = false diff --git a/docs/developer/server/push-notifications.md b/docs/developer/server/push-notifications.md new file mode 100644 index 0000000..2207fb9 --- /dev/null +++ b/docs/developer/server/push-notifications.md @@ -0,0 +1,24 @@ +# Push Notifications + +Endpoints for web-push are kept in the table `subscription`, along with keys +necessary for signing messages sent to those endpoints. + +The server is responsible for processing events and determining, on a +user-by-user basis, whether they warrant triggering a web-push event. + +As the logic around what _can_ trigger a push evolves, we will keep this +documentation up to date. + +## Events that can trigger push + +- A new channel is created +- A new message arrives in a channel +- A new message containing your username arrives in a channel +- A new message containing a keyword you have configured arrives in a channel +- A message you wrote is stitched +- A message you have flagged is stitched + +## Current Configuration options + +The web client currently supports setting all of these options, but the server +does not store or honour these settings. -- cgit v1.2.3