⚽ Convocados Docs GitHub

Notifications

Get notified when players join or leave your game.

How it works

Convocados uses Web Push Notifications (via the Push API and Service Workers). No app install is needed — notifications work directly in the browser.

Subscribing

  1. Open an event page
  2. Click Get notified
  3. Allow notifications when the browser prompts you

The button changes to Notifications on (green). Click it again to unsubscribe.

What you'll receive

EventNotification
Player joins (active)"Alice joined the game · 3 spot(s) left"
Player joins (bench)"Alice joined the bench · Game is full"
Player leaves"Alice left the game · 1 spot(s) left"
Player leaves + promotion"Alice left · Bob is now playing"
Self-suppression: You won't receive notifications for your own actions. This is tracked via a client ID stored in localStorage.

Browser support

Push notifications work in Chrome, Edge, Firefox, and Safari 16.4+. If the browser doesn't support push, the notification button is hidden. If the user has blocked notifications, the button shows "Notifications blocked".

VAPID keys (self-hosting)

Push notifications require VAPID keys. Generate them with:

npx web-push generate-vapid-keys

Set the output as environment variables:

VAPID_PUBLIC_KEY="BPx..."
VAPID_PRIVATE_KEY="abc..."

Without these keys, push notifications are silently disabled — the rest of the app works fine.

Localization

Notification text is sent in the subscriber's language (detected from navigator.language). Currently English and Portuguese are supported.