v1.0 Dashboard Public Profile GitHub
⏳ ~55% Complete Phase 4

Phase 4 — CRM & Customer Retention

Customer profiles, lead pipeline, segmentation, missed-call recovery, review requests, and lifetime value tracking — giving businesses a full picture of every customer.

What It Does

Every caller automatically gets a customer record created. The CRM shows full history: all calls, transcripts, appointments, and spend. Customers are automatically segmented (lead/active/inactive/VIP) and can be moved through a 5-stage sales pipeline. Missed calls are caught in a recovery queue so no lead is lost.

Key Routes

URLDescription
GET /customersCustomer list with segmentation filters
GET /customers/createCreate customer manually
GET /customers/{id}Customer profile — calls, appointments, spend, notes
PUT /customers/{id}Update customer details
DELETE /customers/{id}Delete customer (owner only)
POST /customers/{id}/move-stageMove customer to a pipeline stage
POST /customers/{id}/send-review-requestSend review request SMS
GET /leadsLead pipeline — 5-stage Kanban view
GET /missed-callsMissed-call recovery queue
POST /missed-calls/{id}/send-smsSend follow-up SMS from recovery queue
POST /missed-calls/{id}/mark-handledMark missed call as handled

Key Files

TypePath
Controllerapp/Http/Controllers/CustomersController.php
Serviceapp/Services/CustomerService.php — syncStats(), VIP auto-promote
Modelapp/Models/Customer.php
Tablecustomers — name, phone, email, segment, pipeline_stage, source, total_appointments, total_spent, last_visit_at, review_requested_at

Customer Segments

SegmentCriteria
leadCalled or messaged, never booked an appointment
activeHas booked at least one appointment in the last 6 months
inactiveNo activity in 6+ months — auto-set by CustomerService::syncStats()
vip10+ total appointments — auto-promoted by CustomerService::syncStats()

Lead Pipeline Stages

  1. New Lead
  2. Contacted
  3. Appointment Set
  4. Converted
  5. Lost

Customers are moved between stages via the pipeline Kanban view or from the customer profile. Stage changes fire the lead_stage_changed automation trigger.

What's Complete

  • Customer profiles: index page with segment + source filters
  • Customer show page: booking history, call transcripts, total spent, notes
  • Customer CRUD: create, update, delete
  • Lead Pipeline page with 5 stages and one-click stage movement
  • Missed-call recovery queue with manual SMS send or mark handled
  • Review request SMS (one-click, tracks review_requested_at)
  • Revenue/LTV display: total_spent shown on customer profile
  • Auto-promote to VIP at 10+ appointments (CustomerService::syncStats)
  • Auto-mark inactive after 6 months no activity

What's Deferred

  • Loyalty programs (points, tiers, rewards)
  • Customer reactivation campaigns ("We miss you" automated flows)
  • Automated upsells (post-appointment offers)
  • Referral system (customer referral tracking + rewards)
  • Feedback loops (post-visit satisfaction surveys)
  • Churn prediction (ML/heuristic at-risk scoring)