Lifecycle operations / sports marketplace · Public workflow example · No-send demo by default
Identify users whose engagement is declining and choose an SMS or WhatsApp follow-up channel. This example is informed by my customer-operations work at JoGo.Team and demonstrates the workflow with sample records.
My contribution is connecting customer-health signals to an actionable retention workflow through AI-assisted implementation: score activity, identify candidates, select a channel, and personalize the message.
Sample activity -> Health score -> At-risk threshold -> Channel decision
|
No-send preview
The public example includes scoring and Twilio sender modules. It does not include the production scheduler, consent management, webhook handling, response tracking, or a verified outcome dataset. No reactivation percentage is claimed for this demonstration.
Python 3.10+:
git clone https://github.com/jeypnet/twilio-whatsapp-reengagement.git
cd twilio-whatsapp-reengagement
python -m pip install -r requirements.txt
python reengagement.py --dry-runRunning python reengagement.py also previews only. Neither CLI command sends a message or needs credentials.
Example output format:
DEMO | score=0.00 | channel=SMS
DEMO | score=27.50 | channel=WhatsApp
...
Demo complete: 6 candidates; 0 messages sent.
The sample contains fixed historical dates, so results can change with the date of execution. Preview output omits names, phone numbers, and email addresses.
| File | Responsibility |
|---|---|
health_score.py |
Login recency, sessions, bookings, profile completion; at-risk threshold of 40 |
reengagement.py |
SMS below 20; WhatsApp for other at-risk scores; no-send CLI |
twilio_sms.py / twilio_whatsapp.py |
Messaging integration modules |
config.py |
Sample file location and environment-based configuration |
users_sample.csv |
Example records with example.com addresses and placeholder phone numbers |
The sender modules are provided for code review; this is not a turnkey production messaging service. Production use needs consent and opt-out handling, approved message templates where required, a background queue, duplicate-send protection, and delivery tracking. The public CLI deliberately exposes only the preview.
No credentials are included. Configuration reads process environment variables rather than loading a .env file. Keep real contacts, exports, environment files, and logs outside version control.
