{
  "schema": "codee.remote.v1",
  "version": "2026.08.29-browser-first-voice-input-v5",
  "updated_at": "2026-08-29",
  "positioning": "Codee Remote pairs a phone once, reconnects it to a registered Mac with rotating viewer credentials, keeps the host online, and unlocks native input only after explicit owner and macOS approval.",
  "public_page": "https://clients.codee.chat/codee-remote.html",
  "viewer_page": "https://clients.codee.chat/api/remote/viewer",
  "host_page": "https://clients.codee.chat/api/remote/host",
  "cli_bridge_page": "https://clients.codee.chat/codee-owner-cli.html",
  "installer_page": "https://clients.codee.chat/api/remote/installer",
  "demo_page": "https://clients.codee.chat/codee-remote-demo.html",
  "security_page": "https://clients.codee.chat/codee-remote-security.html",
  "manifest_url": "https://clients.codee.chat/api/remote/manifest",
  "toolbox_url": "https://clients.codee.chat/api/remote/toolbox",
  "host_download_url": "https://clients.codee.chat/assets/downloads/codee-remote-host.py",
  "mac_setup_url": "https://clients.codee.chat/api/downloads/codee-remote-mac.command",
  "entitlement_required": ["pro", "partner", "business-suite", "owner-admin"],
  "public_active_status": {
    "foundation_live": true,
    "owner_toolbox_live": true,
    "remote_cli_bridge_live": true,
    "python_command_host_live": true,
    "browser_screen_streaming_live": true,
    "native_host_screen_streaming_live": false,
    "active_input_control_live": true,
    "trusted_device_reconnect_live": true,
    "background_host_service_live": true,
    "dedicated_remote_pwa_live": true,
    "disability_first_simple_mode_live": true,
    "expanded_pointer_controls_live": true,
    "certificate_free_browser_setup_live": true,
    "phone_keyboard_voice_text_live": true,
    "unsigned_command_download_deprecated": true,
    "status_copy": "The primary Mac route is browser-first: readable host source is copied through Terminal, fingerprint verified, and optional native input is compiled locally. No unsigned app is launched. Phone keyboard, keyboard dictation, optional browser speech recognition, visible screen consent, one-tap trusted reconnect, accessibility preferences, expanded controls, rotating credentials, and the four-command bridge are implemented. Native unattended screen capture and passkeys are not yet implemented."
  },
  "upgrade_readiness": [
    {"id":"native-screencapturekit-host","status":"pending","reason":"browser capture still requires visible Mac screen selection"},
    {"id":"signed-notarized-mac-package","status":"deferred-not-required-for-browser-route","reason":"browser-first source setup avoids launching an unsigned app; signed packaging can be added later"},
    {"id":"automatic-reboot-sleep-network-restore","status":"foundation-live","reason":"LaunchAgent, room heartbeat, rotating trusted reconnect, and ICE restart are implemented; browser capture must still be re-approved after browser or Mac restart"},
    {"id":"passkey-face-id","status":"pending","reason":"trusted device token is implemented but WebAuthn step-up is not"},
    {"id":"simple-device-dashboard","status":"live-v4","reason":"saved Macs render as large one-tap connect actions with advanced tools collapsed"},
    {"id":"richer-remote-controls","status":"live-v4","reason":"touchpad, keyboard pointer, left click, right click, double click, scrolling, text, and special keys are implemented"},
    {"id":"adaptive-streaming","status":"pending","reason":"current browser capture uses fixed frame-rate constraints"},
    {"id":"signed-automatic-updates-rollback","status":"pending","reason":"release channel metadata exists but signed updater and rollback are not implemented"},
    {"id":"physical-iphone-cellular-endurance-proof","status":"pending-physical-test","reason":"automated WebRTC proof is not a physical cellular endurance run"},
    {"id":"simpler-enrollment","status":"live-v4","reason":"QR pairing auto-fills and connects, then trusted reconnect becomes one tap"}
  ],
  "moves": [
    {"id": "desktop-host-skeleton", "status": "foundation-live", "proof": "codee-remote-host.py download and host command"},
    {"id": "secure-device-pairing", "status": "foundation-live", "proof": "remote pair packet with expiration and device id"},
    {"id": "device-registry-plan", "status": "foundation-live", "proof": "remote host profile and installer manifest"},
    {"id": "session-start-stop-api-plan", "status": "foundation-live", "proof": "remote session command and session packet"},
    {"id": "phone-viewer-shell", "status": "foundation-live", "proof": "codee-remote-viewer.html with owner toolbox"},
    {"id": "desktop-consent-banner-rule", "status": "foundation-live", "proof": "remote security gate and viewer rules"},
    {"id": "emergency-stop-rule", "status": "foundation-live", "proof": "remote security gate blocks silent control"},
    {"id": "remote-cli-command-queue", "status": "foundation-live", "proof": "remote bridge command and host skeleton queue file"},
    {"id": "cli-allowlist-lock", "status": "foundation-live", "proof": "remote bridge blocked actions and host allowlist"},
    {"id": "audit-log-events", "status": "foundation-live", "proof": "remote audit command and event trail"},
    {"id": "entitlement-gate", "status": "foundation-live", "proof": "remote manifest requires pro or business-suite"},
    {"id": "portal-remote-controls-plan", "status": "foundation-live", "proof": "remote portal URLs in pairing/session packets and toolbox manifest"},
    {"id": "remote-installer-page", "status": "foundation-live", "proof": "codee-remote-installer.html"},
    {"id": "host-self-update-plan", "status": "foundation-live", "proof": "remote host download URL and stable channel note"},
    {"id": "webrtc-signaling-plan", "status": "foundation-live", "proof": "remote manifest backend components"},
    {"id": "turn-relay-plan", "status": "foundation-live", "proof": "remote manifest specialized components"},
    {"id": "playwright-proof-targets", "status": "foundation-live", "proof": "404 loop targets for remote pages"},
    {"id": "remote-readiness-scan", "status": "foundation-live", "proof": "remote readiness command"},
    {"id": "public-demo-mode", "status": "foundation-live", "proof": "codee-remote-demo.html and demo command"},
    {"id": "security-review-gate", "status": "foundation-live", "proof": "codee-remote-security.html and security command"}
  ],
  "phases": [
    {
      "id": "desktop-viewer-mvp",
      "status": "live-browser-viewer",
      "summary": "Phone opens a viewer page, pairs with the user's own desktop host, and receives a user-approved screen stream.",
      "components": ["PWA viewer", "desktop host agent", "pairing code", "WebRTC signaling", "TURN relay", "visible consent banner", "session revoke"]
    },
    {
      "id": "remote-cli-bridge",
      "status": "live-four-command-bridge",
      "summary": "Phone or browser sends Status, Doctor, Heartbeat, or Scan to the paired Python host. Results and a sanitized audit trail return to the viewer.",
      "components": ["PWA command panel", "Codee backend command queue", "desktop host agent", "allowlisted CLI runner", "audit log"]
    },
    {
      "id": "desktop-remote",
      "status": "beta-native-input",
      "summary": "Owner-approved native mouse and keyboard input is available through a locally built helper and macOS Accessibility permission. Browser capture still requires a visible desktop consent click.",
      "components": ["native host", "mobile web client", "device registry", "MFA/passkey", "policy engine", "emergency lock"]
    }
  ],
  "gcloud_components": ["Cloud Run API", "Firestore or Cloud SQL session store", "Pub/Sub command queue", "Cloud Storage proof artifacts", "Secret Manager", "Firebase Hosting PWA"],
  "specialized_components": ["TURN relay on Compute Engine or managed TURN", "native host app for macOS/Windows", "code signing and notarization"],
  "viewer_capabilities": ["phone browser viewer", "owner toolbox", "pairing code", "visible consent", "proof export", "browser screen stream", "emergency stop"],
  "cli_bridge_capabilities": ["status", "doctor", "heartbeat", "scan"],
  "owner_toolbox": [
    {"id": "pair-phone", "title": "Pair Phone", "status": "foundation-live"},
    {"id": "start-visible-session", "title": "Start Visible Session", "status": "foundation-live"},
    {"id": "emergency-stop", "title": "Emergency Stop", "status": "foundation-live"},
    {"id": "queue-heartbeat", "title": "Queue Heartbeat", "status": "foundation-live"},
    {"id": "queue-doctor", "title": "Queue Doctor", "status": "foundation-live"},
    {"id": "queue-route-scan", "title": "Queue Route Scan", "status": "foundation-live"},
    {"id": "open-codeemail", "title": "Open CODEEMAIL", "status": "foundation-live"},
    {"id": "open-admin-hq", "title": "Open Admin HQ", "status": "foundation-live"},
    {"id": "open-consultation-room", "title": "Open Consultation Room", "status": "foundation-live"},
    {"id": "export-proof", "title": "Export Proof Packet", "status": "foundation-live"}
  ],
  "security_gate": [
    "pairing code expiration",
    "visible desktop consent banner",
    "phone and desktop emergency stop",
    "MFA or passkey before public active control",
    "device registry with revoke",
    "session audit trail",
    "allowlisted CLI commands only",
    "no public owner credentials",
    "no unattended control by default",
    "security review before screen input ships"
  ],
  "security_rules": [
    "No unattended full desktop control until the device owner explicitly enables it.",
    "The viewer requires visible consent, a live session banner, and a user-controlled stop button.",
    "Remote CLI bridge starts with allowlisted Codee commands only.",
    "Pairing codes expire quickly and can be revoked from the portal.",
    "Every command writes an audit event and proof report.",
    "No Stripe secret keys, OAuth refresh tokens, or owner deploy credentials are shipped to public clients.",
    "Full remote desktop requires MFA/passkey, visible session indicator, and emergency stop."
  ],
  "first_commands": [
    "python3 codee.py remote plan . --write --force",
    "python3 codee.py remote installer . --write --force",
    "python3 codee.py remote host . --write --force",
    "python3 codee.py remote viewer . --write --force",
    "python3 codee.py remote toolbox . --write --force",
    "python3 codee.py remote bridge . --write --force",
    "python3 codee.py remote pair . --device-name \"Mac Studio\" --write",
    "python3 codee.py remote security . --write --force",
    "python3 codee.py remote readiness . --write --force",
    "python3 codee.py portal . --service codeeqr --plan pro"
  ]
}
