Agent API accepts X-Tray-Key pushes; Electron tray captures cookies and upserts accounts by email. |
||
|---|---|---|
| .. | ||
| src | ||
| package.json | ||
| README.md | ||
| tsconfig.json | ||
Media Cluster Token Tray
Windows system-tray helper die Viaplay-sessie-tokens vernieuwt en naar de master-api pusht.
Server
Zet in master-api .env:
TOKEN_TRAY_SECRET=minstens-16-willekeurige-tekens
Endpoint:
GET /api/v1/agent/status— headerX-Tray-KeyPOST /api/v1/agent/viaplay/tokens— body:email,session,accessToken, optioneelprofileId/label/persistentLogin
Lokaal starten
cd apps/token-tray
pnpm install
pnpm dev
- Vul API URL + Tray key (=
TOKEN_TRAY_SECRET) - Vul het zelfde e-mailadres als het Scripts → Viaplay account
- Tray → Viaplay inloggen / vernieuwen (CAPTCHA in het venster)
- Tray → Tokens naar server sturen
Configbestand: %APPDATA%/token-tray/tray-config.json (Electron userData).
MVP-scope
- Alleen Viaplay
- Browserprofiel per account (cookies blijven lokaal)
- Handmatige push na login + JWT-expiry waarschuwing in tooltip/notificatie
- Nog geen Odido/F1, nog geen stille background-refresh zonder browser