# Fixing Campaign Errors - Quick Guide ## Why Are Messages Failing? Your campaign shows failed messages because of **compliance checks** that protect you from sending spam. This is a GOOD thing! 🛡️ ## Common Errors & Fixes ### 1. "Contact not opted in; must use approved template" **Problem**: Contact hasn't given permission to receive messages. **Fix Option A** (Recommended for testing): 1. Go to **Contacts** page 2. Find the contact(s) that failed 3. Click **Edit** (you'll need to add this feature OR recreate contact) 4. Check the **"Opted In"** checkbox ✅ 5. Save **Fix Option B**: Use approved WhatsApp template (see #2 below) ### 2. "No conversation window; must use approved template" **Problem**: WhatsApp requires approved templates for cold outreach. **Fix**: Mark your template as approved: 1. Go to **Templates** page 2. Edit your template 3. Check **"Approved WhatsApp Template"** checkbox ✅ 4. Save **Note**: In production, you'd actually submit templates to Meta for approval. For testing, just check this box. ### 3. Using Telegram for Easy Testing Instead of dealing with WhatsApp compliance, use Telegram (100% free!): 1. Set in `docker-compose.yml`: ```yaml WHATSAPP_PROVIDER: telegram TELEGRAM_BOT_TOKEN: ``` 2. Follow **TELEGRAM_TESTING.md** guide 3. Add contacts with Telegram user IDs instead of phone numbers 4. Messages will actually be delivered to Telegram! 📱 ## Quick Test Checklist Before sending campaigns: - [ ] All contacts have **"Opted In"** checked - [ ] Template has **"Approved WhatsApp Template"** checked (if not using Telegram) - [ ] Contacts are in a list - [ ] Campaign created with that list and template - [ ] Worker triggered after clicking "Send" ## Production Note In production with real WhatsApp: - Only send to contacts who explicitly opted in (GDPR compliance) - Submit templates to Meta for approval (takes 24-48 hours) - Use approved templates for first contact - Free-form messages only for existing conversations For now, just check the boxes for testing! ✅