- From: Marco Colli <notifications@github.com>
- Date: Mon, 03 Sep 2018 04:18:27 -0700
- To: w3c/push-api <push-api@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Monday, 3 September 2018 11:18:48 UTC
> after some time the user logs out Take a look at the [Pushpad Javascript SDK](https://pushpad.xyz/docs/javascript_sdk_reference): we manage that. See the `uid` option of `unsubscribe` in particular. Basically when the user logs out you can send a request to the application server like this: `/remove_user_id?endpoint=...`. When the server receives that request, it finds the endpoint in your database and removes any association to the user: in this way you will stop sending personal notifications to that endpoint. Also I recommend that you associate an endpoint at most to one user at a time: never associate an endpoint to multiple users at the same time because it doesn't make sense and it will become a nightmare (we did that in the past and [we had to change](https://blog.pushpad.xyz/2016/10/pushpad-sdk-change-one-subscription-per-browser-instead-of-multiple-subscriptions-for-each-uid/)). -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/w3c/push-api/issues/297#issuecomment-418084563
Received on Monday, 3 September 2018 11:18:48 UTC