Skip to content

feat: add SMS fleet mode for distributed campaign sending#2764

Closed
baderdean wants to merge 28 commits intomainfrom
feat/sms-fleet-mode
Closed

feat: add SMS fleet mode for distributed campaign sending#2764
baderdean wants to merge 28 commits intomainfrom
feat/sms-fleet-mode

Conversation

@baderdean
Copy link
Copy Markdown
Member

Adds fleet mode capability to distribute SMS sending across multiple gateways/phones

- Add SMS campaign tables (sms_campaigns, recipients, link_clicks, unsubscribes)
- Add unified campaign overview RPC returning both email and SMS
- Create SMS campaign edge function with SmsGate, Simple SMS Gateway, and Twilio providers
- Add short-link utility using is.gd for click tracking
- Add quota enforcement (daily/monthly limits)
- Add new SMS campaign composer dialog with provider setup
- Add SplitButton for email/sms campaign actions in MiningTable
- Add QR codes for provider setup (Play Store, APK download)
- Add MiningTable refactoring for SMS campaign button
- Update campaign page with channel badge and metrics
- Add filters store for table preferences
- Add i18n translations for SMS
- Add tests for mining table performance and preferences
- Improve email campaign proxy for SMS links
- Fix various minor issues
- Add sms_fleet_gateways table for managing multiple SMS gateways
- Add sms_campaign_recipient_gateways table for tracking assignments
- Update sms_campaigns with fleet_mode_enabled and selected_gateway_ids
- Create fleet gateway management endpoints (CRUD + test)
- Update campaign creation to support fleet mode
- Update campaign processing to distribute across gateways
- Add FleetGatewaySelector component for campaign creation UI
- Add SmsFleetManagement component for user profile
- Add sms-fleet store for state management
- Update SMS campaign composer with fleet mode toggle

Fleet mode allows users to configure multiple SMS gateways/phones
and distribute campaign sending across them for faster delivery.
Comment thread frontend/src/pages/account/settings.vue Outdated
const smsgatePasswordInput = ref('');
const simpleSmsGatewayBaseUrlInput = ref(
$profile.value?.simple_sms_gateway_base_url ||
'http://192.168.1.100:8080/send-sms',
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hardcoded localhost

Comment thread frontend/src/pages/account/settings.vue Outdated
const passwordInput = ref('');
const smsgateBaseUrlInput = ref(
$profile.value?.smsgate_base_url ||
'https://api.sms-gate.app/3rdparty/v1/messages',
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hardcoded url

Comment thread supabase/functions/sms-campaigns/utils/phone.ts
Resolved conflicts favoring fleet mode functionality:
- Fleet mode gateway distribution and management
- Default provider URLs (SMSGate/simple-sms-gateway)
- Campaign split button for email/SMS
- Phone validation with libphonenumber-js
- Remove unused SmsFleetGateway type import from FleetGatewaySelector.vue
- Remove commented CampaignButton and its unused import from MiningTable.vue
Removed duplicate watcher declaration from merge conflict residue.
Kept the more complete version with observeTop() and watchEffect.
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 5, 2026

Coverage Report

Passed

Commit: 286f659

Summary

Name Stmts Branch Funcs Lines
🔴 Total 38.5% 35.6% 44.7% 38.6%

Generated by Test Coverage Reporter for commit 286f659


function openFleetGatewayDialog() {
// Navigate to profile page with fleet management tab open
window.open('/settings?tab=sms-fleet', '_blank');
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use navigateTo for smoother navigation

@baderdean
Copy link
Copy Markdown
Member Author

Needs much more polishing before being merge

@baderdean baderdean closed this Apr 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants