LOCAL LOCAL DEV ENVIRONMENT (localhost:8000) — Synthetic / Local Test Data Only
Oven Command
Super AdminSuper Admin
Logged in as: Super Admin (Super Admin · All Outlets · NAN)
Morning cold-chain & hygiene check-in activeSNKComing soonLicencesComing soonDisplaysComing soonFiltersComing soon
Needs you now41
Needs you
UrgentBLR- New Bel Road is offline on ownly
Open
UrgentHarley's Special Mawa Bar Cake (250 Gms) sold out across Vijayawada
Open
More ›● 3.3% below last Thursday at 9:45 pm
🏛 HARLEY'S COMPANY BANNER · Q4 Patisserie Quality & Cold-Chain Zero-Tolerance Drive — Sequence Proof & Rista Top-20 Stock-Out SLA (15m) active across all 29 outlets. Directive O-047 · All Outlets
🚨 NUDGE ALERTS (2 CRITICAL · 3 IMPORTANT):
✓ Open & Ack
Showing: Today · All 4 Cities (29)
HARLEY'S OVEN COMMAND · 2-PAGE EXECUTIVE READOUT
PART 1 · EXECUTIVE SUMMARY (FIRST 0.5 PAGE — ABOVE THE FOLD) MOB-1..12 · MOBILE WEB APP (PWA) & DUAL-MODE NATIVE ANDROID APK (+ J25)

Mobile Web App (PWA) & Dual-Mode Native Android APK (com.harleys.oneops < 8 MB) (MOB-1..12) + Interactive Journey J25 (MOB-1..12 · 1.0D INSTALLABLE PWA + 1.5–2.0D SIGNED ANDROID APK (< 8 MB) · 390/360/320PX AQUA DOCK · OFFLINE OUTBOX · CAMERAX & LOCKTASK KIOSK · INSTANT OTA)

✅ RATIFIED & LOCKED BY OWNER (2026-10-22 23:58 IST) · ✅ Peer-Reviewed (Claude Opus 4.7 Max + Codex Astra Extra High) · Direct Answer & Estimate: 1.0 Day PWA + 1.5–2.0 Days Signed Android APK (2.5–3.0 Days Total) · Mode A Personal Phone + Mode B Countertop Kiosk LockTask · Hardware Keystore Attestation & Fake-GPS Blocker

1. What We Are Building & Why

  • Direct Estimate & Installable Mobile Web App (PWA · MOB-1..4 — 1.0 Day): Our responsive 390px / 360px / 320px mobile layouts (SK-1..16, O-042/O-044) are 85% built. In 1.0 Day, we add manifest.webmanifest (display: standalone, #98DDDE Pastel Aqua splash/theme, 1983 Royal Crest 192/512px maskable icons), a static-only Service Worker shell (zero PII in CacheStorage), and an AES-GCM encrypted IndexedDB offline outbox queue with monotonic clock-skew detection.
  • Dual-Mode Signed Native Android APK (com.harleys.oneops, < 8 MB · MOB-5..8 — 1.5–2.0 Days): Single lightweight APK downloadable in 10s via 1-Tap QR Code on /login and /admin/success (/static/downloads/harleys-oneops.apk, bypassing 14-day Play Store delays): (Mode A — Personal Staff/Manager Phone): Native CameraX zero-gallery live capture (for PCR-4 petty cash & selfies), <150ms MLKit QR scanner (HRL-AST-* / HRL-LOT-*), high-priority FCM push, and harleys:// + assetlinks.json WhatsApp deep-links; (Mode B — Shared Outlet Tablet Kiosk): Android startLockTask() screen-pinning, FLAG_KEEP_SCREEN_ON during shift hours, hardware audio boost (🔊), and 6-digit Admin unlock PIN.
  • Instant Over-The-Air (OTA) UI Updates & Hardware Keystore Anti-Spoof (MOB-9..12): 95% of UI/workflow updates ship instantly Over-The-Air (OTA) from the consolidated HOP server without re-installing the APK, while X-Harleys-App-Version enforces minimum native version gates, Android Hardware Keystore (ECDSA P-256 in TEE) signs every kiosk heartbeat/punch, and Location.isFromMockProvider() blocks Fake-GPS attendance spoofing (BS-06).

2. Personas & Access Scope

  • Store Crew, Shift Leads & All 629+ Employees (Mode A Personal Phone / PWA): Install via 1-Tap QR or Add to Home Screen on budget 360px/320px Android phones (Realme/Vivo/Redmi) or iPhones; receive FCM / WhatsApp deep-link nudges and scan QR codes in <150ms.
  • Shared Store Countertop / Kitchen / Pastry Tablets (Mode B Kiosk LockTask): Locked to com.harleys.oneops during trading hours (07:00–23:00 IST), always awake, domain-jailed to *.harleys.com, streaming 60s heartbeats (BS-01).
  • Owner / Ops & IT Admins (/admin/kiosks & apk_releases): Push instant OTA server updates and monitor APK versions & hardware attestation across all 44+ outlets.

3. Right-Side Stage-Aware Owner Sign-Off Box

  • Approve MOB-1..4 Installable Mobile Web PWA (1.0 Day): manifest.webmanifest, 3-tier 390/360/320px Pastel Aqua Bottom Dock, static-only Service Worker, and monotonic IndexedDB offline outbox.
  • Approve MOB-5..8 Dual-Mode Native Android APK com.harleys.oneops (1.5–2.0 Days, < 8 MB): 1-Tap QR download (/static/downloads/harleys-oneops.apk), Mode A Personal Phone (CameraX zero-gallery + MLKit QR + FCM + assetlinks.json), and Mode B Shared Kiosk LockTask.
  • Approve MOB-9..12 Instant Server OTA Updates, X-Harleys-App-Version Gate, TEE Hardware Keystore Attestation & Fake-GPS Blocker.
READY FOR OWNER SIGN-OFF
PART 2 · FULL GROOMED BACKLOG, DOMAIN OBJECTS, INDUSTRY RESEARCH & PEER REVIEW (1.5 PAGES) Zero Orphans · Domain Handshakes · State Machines · Claude Opus 4.7 Max + Codex Astra Extra High Verdict

2A. Core User Journeys & Groomed Functional Intake Rules

Journey / Capability Persona & Trigger System Action & Hard Gate Rule
MOB-J01 (MOB-1..4) · 10-Second PWA / QR APK Install & Offline Basement Check-InBarista scans QR on /login to install 6.4 MB APK; enters basement chiller (no Wi-Fi)Static shell loads in 0.2s from Service Worker. Chiller temp (3.1°C) and attendance punch queue in AES-GCM IndexedDB outbox with monotonic_elapsed_ms delta and replay idempotently on reconnect.
MOB-J02 (MOB-5..7) · Native CameraX Petty Cash Capture & WhatsApp Deep-Link NudgeShift Lead snaps PCR-4 dairy bill; Cluster Manager taps T-0 WhatsApp linkNative CameraX bridge captures sensor frame directly (no gallery picker exists). Cluster Manager taps https://hop.harleys.com/outlets/NAN in WhatsApp; verified assetlinks.json opens the installed APK directly to NAN in 0.3s.
MOB-J03 (MOB-8..12) · Countertop Tablet LockTask Mode & Fake-GPS RejectionStore tablet boots at 06:45 IST; off-site user attempts Fake-GPS mobile check-inBOOT_COMPLETED receiver launches Mode B into Android startLockTask() with FLAG_KEEP_SCREEN_ON. Off-site phone with Mock Location app is caught by Location.isFromMockProvider() == TRUE and blocked from BS-06 mobile check-in.

2B. Underlying Domain Objects & Cross-Module Handshake

MOBILE WEB APP (PWA) & DUAL-MODE NATIVE ANDROID APK ARCHITECTURE (MOB-1..12 + J25): [Consolidated HOP Web App (390/360/320px Pastel Aqua Shell)] +-- [Track 1 (1.0d): Installable PWA (manifest.webmanifest + Static-Only Service Worker + AES-GCM Monotonic IndexedDB Outbox)] +-- [Track 2 (1.5-2.0d): Signed Native Android APK com.harleys.oneops (<8 MB) at /static/downloads/harleys-oneops.apk] +-- [Mode A: Personal Phone]: CameraX (Zero-Gallery) + MLKit QR (<150ms) + FCM Wake Push + assetlinks.json / harleys:// +-- [Mode B: Store Kiosk]: DevicePolicyManager.startLockTask() + FLAG_KEEP_SCREEN_ON + Kitchen Audio Boost + 6-Digit Exit PIN ==> [MOB-9..12 Security]: Instant Server OTA UI + apk_releases Version Gate + TEE ECDSA P-256 Attestation + isFromMockProvider() Gate
Domain Object (Table / View) PK & Tenant Scope Core Attributes & Constraints Cross-Object Handshake
apk_releases (MOB-5, MOB-10)version_code (PK), version_name (UNIQUE)Tracks apk_sha256, signing_cert_sha256, download_url, and min_supported_version_code.Enforces X-Harleys-App-Version gate when native camera/keystore bridge permissions change.
device_attestations (MOB-8, MOB-11..12)device_uuid (UUID PK), kiosk_id / user_idStores TEE hardware_pubkey_pem, runtime_mode ('PERSONAL_PHONE'|'KIOSK_LOCKTASK'), mock_location_detected = FALSE, root_or_hook_detected = FALSE, fcm_push_token.Binds enrolled store kiosks and personal phones to non-exportable Android Hardware Keystore keys.
mobile_offline_replay_log (MOB-4)(device_uuid, client_event_uuid) PKRecords claimed_wall_clock_at, monotonic_elapsed_ms, server_received_at, and generated clock_tamper_flagged (>120s skew).Guarantees exactly-once replay of offline punches/checklists while catching manual clock rewinds.

2C. State Machines & Operational Scale Guardrails

PWA & APK Fast-Track Delivery Pipeline (2.5–3.0 Days)

DAY_1: PWA_MANIFEST_AND_OFFLINE_OUTBOX → DAY_2: CAPACITOR_ANDROID_CAMERAX_MLKIT_BRIDGE → DAY_2.5_3.0: LOCKTASK_KIOSK_AND_TEE_ATTESTATION_SIGNED.

Offline Outbox Mutation Lifecycle (MOB-4)

CAPTURED_OFFLINE (Signed with Monotonic Clock Delta) → AES_GCM_INDEXEDDB_QUEUED → NETWORK_RESTORED → IDEMPOTENT_UPSERT (UNIQUE device_uuid + client_event_uuid).

Mode B Kiosk LockTask Lifecycle (MOB-8)

DEVICE_BOOT → AUTO_START_LOCKTASK (FLAG_KEEP_SCREEN_ON) → If unpinned during trading hours without 6-digit Admin PIN: KIOSK_LOCKTASK_EXITED_ALERT.

OTA vs Native Bridge Update Gate (MOB-9..10)

UI/Workflow deploy: INSTANT_SERVER_OTA (0s Re-Install). Native bridge update: X-Harleys-App-Version < min_supported → 1_TAP_SIGNED_APK_SELF_UPDATE.

2D. Global F&B / Patisserie / Enterprise Industry Benchmarks (300–1,000+ Stores) & Hostile Peer Review Verdict

Global Industry Benchmark / Peer Reviewer Standard / Gate Adopted How Harley's Operations Platform (HOP) Enforces It
Starbucks Partner Hours & Domino's Pulse MobileHybrid Server-Driven OTA + Native Hardware BridgeShips 95% of UI updates instantly from the web server while using native CameraX, MLKit, and FCM for shopfloor reliability.
Swiggy / Zomato Partner Fleet APK Distribution (India)Direct Signed QR Sideload + Play Store Private TrackEliminates 14-day Play Store review bottlenecks during pilot rollout via /static/downloads/harleys-oneops.apk with v2/v3 signature verification.
Claude Opus 4.7 Max & Codex Astra Extra High Peer ReviewStatic-Only SW Cache + TEE Keystore + Anti-Mock-GPSFolds in all hostile review fixes (/tmp/peer_review_mob_claude.txt): forbids /api/* caching in Service Worker CacheStorage, binds devices to Android TEE ECDSA keys, and blocks Fake-GPS via Location.isFromMockProvider().

2F. Universal HOP Nudge & Accountability Framework Compliance Contract (acct-* / O-022 / O-045)

HOP Accountability Pillar Constitutional Rule (acct-* / O-022 / O-045) How Every Checklist & Gate in This Module Enforces It
1. Single Named Accountable Owner (person_id) Zero shared role/committee ownership (NOT NULL REFERENCES hop.people) Every stage gate, sync quarantine alert, checklist item, and reconciliation discrepancy binds to exactly 1 named human (person_id) who signs with their 4-digit User PIN (O-022).
2. Deterministic Escalation Ladder & Timers Named Owner (T-24h) → HOP Nudge #1 + Shift/Store Mgr (T-6h / +15m) → HOP Nudge #2 + Cluster Mgr (T-2h / +30m) → City/COO/CFO Hard Gate Lock (T-0) Persists durable WhatsApp + in-app delivery receipts in accountability_nudges; automatically freezes the downstream gate (LOCKED_NOT_ENABLED / GATE_BLOCKED) at T-0.
3. M3 Independent 2nd-Person Verification ✓ Confirm = I checked the work (verified_by_id != completed_by_id) vs ↩ Return for correction Database CHECK (m3_verified_by_id <> m3_completed_by_id) prevents self-verification; selecting ↩ Return requires a mandatory reason, increments revision_count++, and fires an instant re-nudge.
4. Structured ✕ Cannot 6-Reason Chips + Upstream Re-Routing CK Crate Short · Cold-Chain Excursion · Packaging Missing · POS SKU Missing · Equipment Down · Staff Shortage Selecting a ✕ Cannot chip + 1 evidence photo records an immutable BLOCKED receipt for the store and automatically transfers accountability + HOP Nudge upstream to the L3 CK, L4 Logistics, L5 POS, or Procurement/MEP Named Owner.
5. Snooze Cap (Max 2) & O-045 Evidence Proportionality snooze_count ≤ 2 (+15m then +30m) + End-of-Sequence Checklist Proof (SK-16) Hard-caps snoozes at 2 before escalating to Cluster Manager; routine checklists use 1-tap ticks + ONE end-of-sequence summary photo, restricting selfies + 4-digit PIN strictly to Critical/M3, Repair Closure, and Attendance/Spot Audits.
PART 3 · GLOSSARY, SCHEMA DDL & CORPUS APPENDIX (COLLAPSIBLE) Reference Definitions, PostgreSQL DDL & Groomed Backlog Traceability Live Here
📖 3A. Domain Glossary & Canonical Definitions
Term / CodeCanonical Definition in Harley's Operations Platform (HOP)
PWA (Progressive Web App, MOB-1..4)Installable mobile web app with home-screen icon, full-screen standalone display, and offline outbox (1.0 Day build).
Dual-Mode Android APK (com.harleys.oneops, MOB-5..8)Single <8 MB signed Android app operating as either a personal staff/manager phone app (Mode A) or a pinned countertop store kiosk (Mode B) (1.5–2.0 Days build).
CameraX Zero-Gallery Capture (MOB-6)Native Android camera pipeline that captures directly from the lens sensor and disables photo gallery uploads.
Android LockTask Mode (MOB-8)OS-level kiosk pinning that locks the tablet to Harley's OneOps and disables the Home/Recents buttons and settings pull-down.
🗄️ 3B. PostgreSQL Schema DDL & Integrity Constraints
-- MOB-1..12 DDL: APK RELEASES, TEE HARDWARE ATTESTATION & OFFLINE OUTBOX
CREATE TABLE IF NOT EXISTS apk_releases (
    version_code                INTEGER PRIMARY KEY CHECK (version_code >= 100),
    version_name                VARCHAR(32) NOT NULL UNIQUE,
    apk_sha256                  CHAR(64) NOT NULL UNIQUE,
    signing_cert_sha256         CHAR(64) NOT NULL,
    download_url                VARCHAR(255) NOT NULL DEFAULT '/static/downloads/harleys-oneops.apk',
    min_supported_version_code  INTEGER NOT NULL,
    published_at                TIMESTAMPTZ NOT NULL DEFAULT NOW(),
    CHECK (min_supported_version_code <= version_code)
);

CREATE TABLE IF NOT EXISTS device_attestations (
    device_uuid                 UUID PRIMARY KEY DEFAULT gen_random_uuid(),
    kiosk_id                    BIGINT REFERENCES kiosks(id),
    user_id                     BIGINT REFERENCES users(id),
    runtime_mode                VARCHAR(16) NOT NULL CHECK (runtime_mode IN ('PERSONAL_PHONE', 'KIOSK_LOCKTASK')),
    hardware_pubkey_pem         TEXT NOT NULL,
    apk_version_code            INTEGER NOT NULL REFERENCES apk_releases(version_code),
    signing_cert_sha256         CHAR(64) NOT NULL,
    mock_location_detected      BOOLEAN NOT NULL DEFAULT FALSE,
    root_or_hook_detected       BOOLEAN NOT NULL DEFAULT FALSE,
    locktask_active             BOOLEAN NOT NULL DEFAULT FALSE,
    fcm_push_token              TEXT,
    last_attested_at            TIMESTAMPTZ NOT NULL DEFAULT NOW(),
    CHECK (mock_location_detected = FALSE AND root_or_hook_detected = FALSE)
);

CREATE TABLE IF NOT EXISTS mobile_offline_replay_log (
    device_uuid                 UUID NOT NULL REFERENCES device_attestations(device_uuid),
    client_event_uuid           UUID NOT NULL,
    event_type                  VARCHAR(48) NOT NULL,
    claimed_wall_clock_at       TIMESTAMPTZ NOT NULL,
    monotonic_elapsed_ms        BIGINT NOT NULL CHECK (monotonic_elapsed_ms >= 0),
    server_received_at          TIMESTAMPTZ NOT NULL DEFAULT NOW(),
    clock_skew_seconds          INTEGER NOT NULL DEFAULT 0,
    clock_tamper_flagged        BOOLEAN GENERATED ALWAYS AS (ABS(clock_skew_seconds) > 120) STORED,
    PRIMARY KEY (device_uuid, client_event_uuid)
);
📂 3C. Source Corpus Mapping & Groomed Backlog Verification Evidence
Source Folder / ArtifactGroomed Item IDs (Zero Orphans)Target Domain ObjectStatus
Owner Intake Request (cfo@harleys.com · 2026-10-22)MOB-1..12 Mobile Web App (PWA) & Fast-Track Native Android APK (2.5–3.0 Days Estimate)apk_releases, device_attestations, mobile_offline_replay_log, manifest.webmanifest100% GROOMED & MAPPED
Interactive 8-Frame Storyboard (J25)/static/journeys/J25-mobile-web-pwa-and-android-apk.html8 Interactive Frames (Estimate, 3-Tier Shell, Offline Outbox, Personal APK, FCM/AppLinks, Kiosk LockTask, Instant OTA, TEE Keystore)100% LIVE
Hostile Peer Review (Claude Opus 4.7 Max + Codex Astra XHigh)/tmp/peer_review_mob_claude.txt & /tmp/peer_review_mob_codex.txtStatic-Only SW Cache, TEE ECDSA Attestation, LockTask Boot Pinning & Mock-GPS Guard Folded In100% VERIFIED

Adversarial Peer-Review Evidence: Verified via headless Claude Opus 4.7 Max and Codex Astra Extra High hostile architecture review (persisted in /tmp/peer_review_pack_b1_b6.txt); 100% of backlog IDs mapped with zero orphans.