feat: SMS enhancements - fallback + two-way messaging#24
Open
jordanbench wants to merge 3 commits intoZeframLou:mainfrom
Open
feat: SMS enhancements - fallback + two-way messaging#24jordanbench wants to merge 3 commits intoZeframLou:mainfrom
jordanbench wants to merge 3 commits intoZeframLou:mainfrom
Conversation
added 3 commits
January 10, 2026 21:12
## SMS Fallback Feature - Added `sendSMS()` method to PhoneProvider interface and Twilio implementation - When AMD detects voicemail (AnsweredBy=machine_*), sends SMS with original message - Configurable via CALLME_SMS_FALLBACK env var (default: true) - Prefixes SMS with "[Claude]" for clarity ## ngrok Domain Fix - Fixed ngrok free tier detection to include both .ngrok-free.dev and .ngrok-free.app - Fixes ZeframLou#21 ## Changes - phone-call.ts: Track answeredByMachine state, send SMS in endCall() - phone-twilio.ts: Implement sendSMS() using Twilio Messages API - types.ts: Add optional sendSMS() to PhoneProvider interface
Adds the ability to send and receive SMS messages: ## New MCP Tools - `send_sms` - Send an SMS text message to the user - `check_messages` - Check for incoming SMS replies ## Webhook - Added `/sms` endpoint to receive incoming SMS from Twilio - Messages are queued in memory (last 50 kept) ## Usage 1. Configure Twilio phone number to send SMS webhooks to ngrok URL + /sms 2. Use send_sms to send messages to user 3. Use check_messages to see if user replied This enables async text-based communication alongside voice calls.
Automatically updates the Twilio phone number's SMS webhook URL to point to the ngrok URL whenever the server starts. This removes the need to manually configure Twilio each time ngrok generates a new URL. - Added configureSmsWebhook() to PhoneProvider interface - Implemented for TwilioPhoneProvider using Twilio API - Called automatically on MCP server startup
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR adds SMS capabilities to CallMe:
1. SMS Fallback on Voicemail (Fixes #21 partially)
When a call goes to voicemail (detected via Twilio AMD), automatically sends the original message as an SMS.
CALLME_SMS_FALLBACKenv var (default: true)AnsweredBy=machine_*)[Claude]for clarity2. Fix ngrok Free Tier Domain Detection (Fixes #21)
ngrok free tier uses both
.ngrok-free.devand.ngrok-free.appdomains. Updated detection to support both.3. Two-Way SMS Support
New MCP tools for text-based async communication:
send_sms- Send an SMS to the usercheck_messages- Check for incoming SMS repliesAdds
/smswebhook endpoint to receive incoming messages from Twilio.New Tools
Configuration
To enable two-way SMS, configure your Twilio phone number's messaging webhook:
<ngrok-url>/smsTest Plan
.ngrok-free.appdomains worksend_smstool sends messages/smswebhook receives incoming messagescheck_messagesreturns queued messages