System Architecture Case Study

Engineering a Unified Digital Ecosystem for Coco Cafe.

A complete architectural breakdown of the custom front-end storefronts, back-of-house operations, and server infrastructure built to scale operations and eliminate friction.

1. Omnichannel POS & E-Commerce

Standalone Kiosk Mode & Smart Modifiers

Engineered a dedicated fullscreen POS UI with a 45-second auto-reset idle timer. The system utilizes a custom algorithmic sorting function that forces "Spice Levels" first, followed by "Chutneys," before listing alphabetical modifiers. Dynamic 1-tap quick adds are intentionally blocked for specific proteins, forcing mandatory customer selections.

Cross-Platform Syncing & Secure Payments

The web storefront shares the exact database architecture as the in-store POS. Web device IDs permanently tag online traffic for the kitchen. Integrated Square's web payment tokenization and strict pickup-time validations prevent scheduling outside operational hours, while in-store card workflows directly wake physical Square Terminals via API.

2. Back-of-House: Dashboard & Inventory Cascade

Live Ticket Grid & Automated Routing

An auto-refreshing dashboard flashes urgent tickets in real-time. A smart-learning dictionary scans item names and modifier keywords (e.g., "empanada") to determine whether a ticket routes to the main kitchen display or the exterior Shack display, all flagged with distinct payment badges (🌐 ONLINE, 💵 CASH, 💳 CARD).

Global Auto-Cascade Inventory System

Created parent-child dependency mapping for base ingredients. If a base drops to zero during a live POS sale, the database instantly forces the exact remaining quantity and a "(Sold Out)" status down to every linked child item and combo across the POS, website, and TV menus.

3. AI Forecasting & Business Intelligence

Predictive Prep Guide (AI Forecasting)

Built an intelligent engine that calculates an 8-week historical average for specific days of the week to predict exact prep quantities. Management can run past dates to generate dual-bar charts comparing projected (orange) vs. actual sold (green) to easily validate accuracy.

Unified Reporting Suite

Features a Velocity Matrix tracking item performance across 30-minute intervals, a 4-Week Same-Day Comparison chart for daily gross revenue, and granular global filtering to isolate "Food Only" or "Drinks Only" for prep cooks.

4. Core Security & Infrastructure

Bulletproof WAF Bypassing & DB Self-Healing

Solved server firewall (ModSecurity) blocks by engineering JavaScript to compress nested JSON cart arrays into encrypted Base64 and URL-encoded strings before transmission. Embedded automatic SQL fallback scripts silently patch the database on the fly if new columns or utf8mb4 emoji support are required.

Promotional Failsafes & Dual-Stacking

Rewrote the Square API payload to fix receipt proration errors, forcing 100% of promo discounts strictly onto food items. The engine gracefully handles mathematical failsafes (preventing API crashes) and safely stacks automatic bulk promotions alongside manually entered codes.