Live data from Hacker News

Show HN: Schedule iMessage Texts from .txt Files

github.com

21–30 of 76 posts

Re: Show HN: Schedule iMessage Texts from .txt Files

#21
If you don’t have an Apple computer but have an iOS device, you can also do something similar with the “Shortcuts.app” + “Calendar.app”.

I have a daily shortcut that runs at X time. Shortcut checks a calendar for events, if today contains one or more events. It will parse the text from these events (comma separated fully qualified phone numbers or iMessage accounts), and send the message contained in the body of the event.

Added bonus here is that I can also send group messages.

If I need to have the message sent on repeat, then I put the cal event on repeat.

I could possibly even have templated messages (ie, insert month and year into message), but I haven’t deep dived into that rabbit hole.

Downside here though is that you need an iOS device to always be on.

Re: Show HN: Schedule iMessage Texts from .txt Files

#23

Earlier quoted context omitted.

Unfortunately no, Apple has usage limits on iMessage / SMS relaying. Many people hack around this, SendBlue.co being the only long running service, but it's full of the graveyard of folks trying to do this.

What does this mean in practice? I leave my Messages app on my laptop open all day and correspond entirely through it with family. Since I'm typing I send messages rapidly at volume. I've never once hit a limit. Think hundreds of responses a day. If an app running on my machine has subclassed the Messages app and is reading strings and sending hit strokes to the (Send) button on my behalf, how can Apple possibly rate…

It's probably like those email providers that allows you some number of outbound emails per, but it's like 200 - 1000. High enough that most users won't ever notice, but low enough that there's no way to use the service commercially.

Re: Show HN: Schedule iMessage Texts from .txt Files

#24

Earlier quoted context omitted.

Unfortunately no, Apple has usage limits on iMessage / SMS relaying. Many people hack around this, SendBlue.co being the only long running service, but it's full of the graveyard of folks trying to do this.

What does this mean in practice? I leave my Messages app on my laptop open all day and correspond entirely through it with family. Since I'm typing I send messages rapidly at volume. I've never once hit a limit. Think hundreds of responses a day. If an app running on my machine has subclassed the Messages app and is reading strings and sending hit strokes to the (Send) button on my behalf, how can Apple possibly rate…

It means test on prod and find out

(lose your main iCloud account... 'bold move Cotton')

Re: Show HN: Schedule iMessage Texts from .txt Files

#25
post #11

Earlier quoted context omitted.

It only works for iMessage texts, unfortunately.

But the Messages application can send texts to non-iPhone numbers...

I tried sending to a non iMessage number, it failed to send, but there may be a way.

Re: Show HN: Schedule iMessage Texts from .txt Files

#26
Here's an Apple Script moving through iMessage to SMS if required. Make sure to add helpers to update the recipients contact to default to SMS, otherwise you're just cluttering your Messages history with failed messages.

--------

tell application "Messages" set phoneNumber to "+15555555555" set messageToSend to "This is a test!"

try set iMessageService to (1st account whose service type = iMessage) set iMessageBuddy to participant phoneNumber of iMessageService

  if exists iMessageBuddy then
   set theMessage to send messageToSend to iMessageBuddy
   delay 2 -- Wait for a short time to allow the message status to update
   
   if status of theMessage is not "delivered" then
    error "iMessage not delivered"
   else
    log ("sent as iMessage to: " & phoneNumber)
   end if
  else
   error "Not an iMessage user"
  end if
 on error
  try
   set SMSService to (1st account whose service type = SMS)
   set SMSBuddy to participant phoneNumber of SMSService
   send messageToSend to SMSBuddy
   log ("sent as SMS to: " & phoneNumber)
  on error
   log ("ERROR: COULD NOT SEND TO: " & phoneNumber)
  end try
 end try
end tell

Re: Show HN: Schedule iMessage Texts from .txt Files

#28
post #11
post #8

Out of curiosity couldn't one recreate Twilio just by running an extended version of this from a Macbook? You could read all inbound messages from the Messages app and reply as well. You could even hook it up to a local LLM and run a small support agent. Is there ANY reason a small business owner couldn't do this and avoid paying SaaS fees?

It only works for iMessage texts, unfortunately.

It can also work for SMSs with some changes in the applescript. We made a very similar tool that use to send automated SMSs to experiment participants 2 times per day. The setup is similar and there is a bash script that is called using cron twice per day and calls a matlab script (similar to the python script here) that calls an applescript. This is the applescript that, in practice, sends iMessage to those with iphone and SMS to those without

https://github.com/earlychildcog/automate_sms_to_participant...

Re: Show HN: Schedule iMessage Texts from .txt Files

#29

Here's an Apple Script moving through iMessage to SMS if required. Make sure to add helpers to update the recipients contact to default to SMS, otherwise you're just cluttering your Messages history with failed messages. -------- tell application "Messages" set phoneNumber to "+15555555555" set messageToSend to "This is a test!" try set iMessageService to (1st account whose service type = iMessage) set iMessageBuddy…

Awesome!!!! Thank you

Re: Show HN: Schedule iMessage Texts from .txt Files

#30

Earlier quoted context omitted.

I’m surprised you went to the trouble of creating an account on here just to post warmed over, 30 year old “Crapple” insults.

Where did you read a crapple insult in his comment?

Comment is removed but my guess is that he's talking about the general very old flame war style stuff like "M$" and "Microshill" and "Crapple" etc. The "us vs them" mentality of computing.
Post reply on HN