# Sprint G012 — Couple Dashboard & Analytics Engine

## Context

Project: INVEETAIRE Digital Invitation Platform

Architecture

Couple Panel
        ↓
Services
        ↓
Models
        ↓
Invitation Renderer
        ↓
Public Invitation

Completed

✅ G004 Media Engine
✅ G005 Image Processing Engine
✅ G006 Guest Engine
✅ G007 Music Engine
✅ G008 QR Attendance Engine
✅ G009 Couple Panel Integration
✅ G010 RSVP Engine
✅ G011 Guest Book Engine

This sprint introduces the Couple Dashboard & Analytics Engine.

---

# Objective

Provide Couples with meaningful engagement analytics focused on invitation delivery and guest interaction.

This is NOT a website analytics dashboard.

Do NOT implement:

- Page Views
- Visitor Counter
- Session Duration
- Bounce Rate
- Device Statistics

Analytics must answer one question:

"What is the current progress of my invitation?"

---

# Core Principles

Analytics are Guest-based.

One Guest = One Identity.

Opening an invitation is more meaningful than page refreshes.

Every metric must help the Couple make decisions.

---

# Scope

## 1. Invitation Delivery

Track guest invitation status.

Each guest should store:

- first_opened_at
- last_opened_at
- view_count

Business Rules

First time opening invitation:

- first_opened_at = current timestamp
- last_opened_at = current timestamp
- view_count = 1

Subsequent opens:

- update last_opened_at
- increment view_count

Dashboard Cards

Total Guests

Opened Invitations

Not Opened

Opening Rate

Example

250 Guests

182 Opened

68 Not Opened

72.8%

Opening Rate =
Opened Guests / Total Guests

---

## 2. RSVP Analytics

Display

Pending RSVP

Attending

Declined

RSVP Rate

Expected Attendance

Expected Attendance =
SUM(confirmed_pax)

RSVP Rate =
Guests Responded / Total Guests

---

## 3. Guest Book Analytics

Display

Approved Wishes

Pending Moderation

Rejected Wishes

Only count wishes.

No charts required.

---

## 4. Recent Activities

Provide chronological activity feed.

Activities include:

Invitation Opened

RSVP Submitted

Wish Submitted

Example

David

Opened invitation

2 minutes ago

-------------------

Maria

Confirmed attendance

2 Guests

5 minutes ago

-------------------

Andi

Submitted a wish

10 minutes ago

Newest first.

---

## 5. Guest Progress Table

Provide searchable table.

Columns

Guest Name

Invitation Opened

RSVP Status

Wish Status

First Opened

Last Opened

Views

Example

David

✓

Attending

✓

20 Jul

Today

3

Maria

✓

Pending

—

Yesterday

Yesterday

1

Andi

—

—

—

—

—

0

---

## 6. Filters

Support

All Guests

Not Opened

Opened

Pending RSVP

Attending

Declined

Has Wish

No Wish

Search by Guest Name

---

## 7. Dashboard Widgets

Display

Invitation Delivery

RSVP Summary

Guest Book Summary

Recent Activities

Guest Progress

Keep dashboard simple.

Avoid unnecessary charts.

---

## 8. Data Integrity

Reuse existing Guest, RSVP and Wish data.

Do NOT duplicate statistics tables.

Statistics should be generated from existing records whenever practical.

Only add guest tracking fields if required.

---

## 9. Renderer Integration

When a guest opens an invitation:

Record

first_opened_at

last_opened_at

view_count

without affecting page performance.

---

## 10. Backward Compatibility

Existing invitations continue working.

Guests without opening history should display:

Not Opened

No breaking changes.

---

# Deliverables

Complete Couple Dashboard.

Invitation Delivery metrics.

RSVP Analytics.

Guest Book Analytics.

Recent Activities feed.

Guest Progress table.

Dashboard filters.

Search.

No website analytics.

---

# Testing Checklist

- First invitation open recorded
- Subsequent opens update last_opened_at
- view_count increments correctly
- Opening Rate calculated correctly
- RSVP Rate calculated correctly
- Expected Attendance calculated correctly
- Guest Book counts correct
- Recent Activities ordered correctly
- Guest Progress table accurate
- Filters working
- Existing invitations unaffected

---

# Expected Result

After Sprint G012:

The Couple Dashboard becomes the operational command center of INVEETAIRE.

Couples can immediately understand:

• Who has opened the invitation.
• Who has not opened it.
• Who has responded.
• Who is attending.
• Expected attendance.
• Who has left a wish.
• Recent guest activities.

Every metric should be actionable and directly useful for managing the wedding invitation process, rather than functioning as generic website analytics.