▸ System Architecture
1. Install & launch
[Android user-app] --POST /api/device/register--> [Backend API] --> [PostgreSQL]
(unclaimed device row created)
2. Claim
[Admin (browser)] --log in (JWT)--> [admin-web] --POST /devices/:id/claim--> [Backend API]
(creates user, links device)
3. Ongoing sync (every app run, and on install/uninstall)
[user-app] --report installed apps--> [Backend API] --> [PostgreSQL: installed_apps]
[user-app] --fetch policy-----------> [Backend API] --> [PostgreSQL: policies]
4. Admin sets policy
[admin-web] --PUT /devices/:id/policy--> [Backend API] --> [PostgreSQL: policies, policy_history]
|
+--FCM push (POLICY_UPDATED)--> [user-app]
5. Enforcement (on-device, offline-capable)
[user-app: AccessibilityService] --watches foreground app--> blocks/allows
using the locally cached policy (no network needed)
▸ App Installation Guide
- Play Store → Account → Play Protect → gear icon (Settings) → turn off "Scan apps with Play Protect" (Improve harmful app detection) → Pause
- Install the APK → "Install unknown apps" warning → Install anyway
- Open the app → Settings → Accessibility → Installed apps → TH2 Control → Not in use → Allow
- If step 3 shows "Access denied for this app" → App info → tap ⋮ (top right) → Allow restricted settings → then redo step 3
Unclaimed Devices
Devices show up here once the app is installed and launched. Name it or attach it to an existing user to claim it.
Loading...
Users / Devices
Loading...
Installed Apps & Policy
Loading...