AuraMatch

byBADSHAH KHAN

Act as a Principal Software Architect and Full-Stack Mobile Engineer. I want to build a Minimal Viable Product (MVP) for a highly secure, localized "Social Dating & Incognito Voice Matching" app tailored for the Pakistani market, inspired by Nudge and AARS Innovations. Do NOT write any UI design, styling, or CSS code. Instead, design a robust, production-grade MVP functional architecture, technical workflow, and database schema. The application uses React Native (Expo) for the frontend, Firebase (Firestore & Cloud Functions) for the backend, and Agora.io for WebRTC real-time voice communications. --- ### 1. MVP SCOPE & FUNCTIONAL SPECIFICATION The MVP must support exactly three high-impact, functional flows: 1. **Intentional "Nudge" Matchmaking:** Instead of swiping, users can browse cards containing specific user prompts/icebreakers. They must spend a "Nudge token" (limited daily supply) to request a connection. 2. **Incognito Random Voice Matching:** An anonymous 1-on-1 voice queue matching system with gender filters. 3. **Dual-Opt-In Identity Reveal:** During the anonymous call, users must both click "Reveal" to exchange full profiles. --- ### 2. CORE WORKFLOWS & LOGICAL STATE MACHINES #### Workflow A: The Incognito Voice Matching Pipeline Design a step-by-step logic gate and connection state machine for the voice queue: - **State 1: Queue Entry:** User requests a match with parameters: `userId`, `userGender`, `targetGenderPreference`. - **State 2: Matchmaking Engine (FIFO Queue):** Explain the priority-matching algorithm using Firestore. How does it pair User A and User B where: - `UserA.targetGenderPreference === UserB.userGender` AND `UserB.targetGenderPreference === UserA.userGender`. - **State 3: Call Initialization:** Trigger Agora RTC token generation via a Firebase Cloud Function, assigning both users to a unique `roomId`. - **State 4: The 180-Second Call State:** Start a 3-minute timer. During this, user profiles, avatars, and real names are hidden behind generic placeholders. - **State 5: The "Reveal" Consent Gate:** - If both users tap "Reveal" before the timer ends -> Transition to **"Matched" State** (unlock chat, exchange real user profiles). - If the timer expires or either user hangs up before mutual consent -> Transition to **"Destroy Room" State** (disconnect call, wipe queue status, return to dashboard). #### Workflow B: The Nudge-Chat Request Loop - User A views User B's prompt-based profile card. - User A taps "Nudge" -> Deducts 1 token from User A's daily `tokenBalance` -> Writes to `nudgeRequests` database. - User B receives a Push Notification. - User B accepts -> Unlocks direct chat. User B declines -> Request is deleted, token is NOT refunded to prevent spamming. --- ### 3. BACKEND & DATABASE ARCHITECTURE (FIRESTORE SCHEMA) Provide a complete, structured, JSON-like NoSQL database schema for Google Cloud Firestore to support this MVP. Explicitly list the fields, types, and document relations for: 1. **`users` (Collection):** - Essential fields for verification, gender, location, daily nudge tokens, and privacy flags. 2. **`voice_queue` (Collection):** - Active users waiting for a call. Fields must track timestamp, connection status, room reference, and matching criteria. 3. **`calls` (Collection):** - Active call sessions, Agora channel IDs, and individual reveal consents. 4. **`nudges` (Collection):** - Tracks incoming requests, statuses (pending/accepted/rejected), and initiator details. 5. **`conversations` & `messages` (Sub-collections):** - Chat structure after matches are secured. --- ### 4. OUTPUT REQUIREMENTS - Provide the complete architectural workflows described step-by-step. - Provide the exact Firebase database structures with data types (e.g., string, boolean, timestamp, reference). - Outline the backend logic required for the Firebase Cloud matching function in pseudo-code. - Do NOT include any visual layouts, Tailwind configurations, React Native screen components, color schemes, or buttons. Focus entirely on structural, workflow, and backend database design.

Landing
Landing

Comments (0)

No comments yet. Be the first!

System Requirements

System Requirement Document
Page 1 of 5

AuraMatch

Introduction

AuraMatch is a secure, localized "Social Dating & Incognito Voice Matching" application tailored for the Pakistani market. The project aims to create a Minimal Viable Product (MVP) inspired by Nudge and AARS Innovations, focusing on unique matchmaking features and privacy-centric interactions.

System Overview

AuraMatch leverages React Native (Expo) for the frontend, Firebase (Firestore & Cloud Functions) for the backend, and Agora.io for WebRTC real-time voice communications. The application is designed to facilitate secure and anonymous interactions between users, with a focus on privacy and user consent.

Functional Requirements as Story Points

  • As a User, I should be able to browse user prompts/icebreakers and spend a "Nudge token" to request a connection.
  • As a User, I should be able to enter an anonymous 1-on-1 voice queue with gender filters.
  • As a User, I should be able to click "Reveal" during a call to exchange full profiles if both parties consent.
  • As a User, I should receive a push notification when someone sends me a "Nudge" request.
  • As a User, I should be able to accept or decline a "Nudge" request, unlocking direct chat if accepted.
  • As a User, I should have a daily limit on "Nudge tokens" to prevent spamming.
Page 2 of 5

User Personas

  • Regular User: Engages in matchmaking and voice calls, uses "Nudge tokens" for connections.
  • Anonymous User: Participates in incognito voice matching with privacy settings.

Core User Flows

Intentional "Nudge" Matchmaking

  1. User browses profile cards with prompts.
  2. User spends a "Nudge token" to request a connection.
  3. Target user receives a push notification.
  4. Target user accepts or declines the request.
  5. If accepted, direct chat is unlocked.

Incognito Random Voice Matching

  1. User enters the voice queue with gender preferences.
  2. Matchmaking engine pairs users based on preferences.
  3. Agora RTC token is generated, and a call is initiated.
  4. Users engage in a 3-minute anonymous call.
  5. Both users can click "Reveal" to exchange profiles.
  6. If mutual consent is not given, the call ends without revealing identities.
Page 3 of 5

Visuals Colors and Theme

[Default โ€” not specified by user]

  • primary: #1A73E8 (Deep Blue)
  • primary_light: #E8F0FE (Light Blue)
  • secondary: #F9AB00 (Amber)
  • accent: #EA4335 (Red)
  • highlight: #FBBC05 (Gold)
  • bg: #FFFFFF (White)
  • surface: rgba(255, 255, 255, 0.8)
  • text: #202124 (Dark Grey)
  • text_muted: #5F6368 (Light Grey)
  • border: rgba(218, 220, 224, 0.2)

Signature Design Concept

Interactive Voice Matching Experience

The homepage features an interactive voice waveform animation that responds to user interactions. As users hover over different sections, the waveform morphs to reveal different features of the app. Clicking on a section expands it to provide more information, creating an engaging and dynamic first impression.

  • Animation: The waveform continuously undulates, with peaks and troughs reacting to user input.
  • Interaction: Hovering over sections highlights them, and clicking expands the section with a smooth transition.
  • Libraries: Utilize motion/react for animations and interactions.
Page 4 of 5

Landing Hero Motion Brief

The landing page showcases a dynamic animation where user inputs (represented as icons) gather around a central waveform. As the waveform animates, it transforms to reveal the outcome of a successful match, symbolizing connection and communication.

  • Layers: Icons representing user actions, central waveform, background elements.
  • Loop: A 10-second loop showing the transformation from input to outcome.
  • Interaction: Hovering over icons provides tooltips with feature descriptions.
  • Responsive: Adjusts layout and animation speed based on screen size.

Interaction Model & Motion Direction

  • Intended Interaction Model: Animated
  • Details: The landing page features moderate scroll-triggered reveals and hover transitions. Interactive elements utilize spring physics for a polished experience.

Non-Functional Requirements

  • High security and privacy for user data.
  • Real-time performance for voice communications.
  • Scalability to handle increasing user base.

Tech Stack

  • Frontend: React Native (Expo)
  • Backend: Firebase (Firestore & Cloud Functions)
  • Real-Time Communication: Agora.io for WebRTC
Page 5 of 5

Assumptions and Constraints

  • The application will primarily serve the Pakistani market.
  • Users will have limited daily "Nudge tokens" to encourage meaningful interactions.
  • The app must comply with local data protection regulations.

Glossary

  • Nudge Token: A virtual currency used to initiate connections.
  • Incognito Voice Matching: An anonymous voice call feature with gender filters.
  • Reveal: A mutual consent action to exchange full profiles during a call.
Landing design preview
Landing: View Info
Login: Sign In
Queue: Set Gender Filter
Queue: Enter Voice Queue
Call: Join Anonymous Call
Call: View Timer
Call: Tap Reveal
Call: Wait Mutual Consent
Profile: View Revealed Profile
Call: Room Destroyed
Call: End Call Early
Dashboard: Return Home
Landing design preview
Landing: View Info
Login: Sign In
Queue: Set Gender Filter
Queue: Enter Voice Queue
Call: Join Anonymous Call
Call: View Timer
Call: Tap Reveal
Call: Wait Mutual Consent
Profile: View Revealed Profile
Call: Room Destroyed
Call: End Call Early
Dashboard: Return Home