Thanks, guys. 3 cents per message does not sound like much, but it is
not scalable.
I set this up sending SMS via email. A couple of warnings for
everyone:
1) AT&T does not auto-truncate the message to 160 characters, so you
must write a script to do that. If you don't, AT&T breaks it up into
multiple messages, and the receiver will get billed for 20 cents per
each 160 chars.
2) When sending via email, EVERYTHING counts in the 160 characters:
your FROM address (HINT: get a new admin address with a single
letter), the recipients address (22 chars right there), SUBJECT, BODY,
and the header labels (FRM:, SUBJ:, MSG:), plus another 8 or 9
characters (maybe the date or the fake number GAE sends from). So,
you end up with A LOT less than 160 chars to send in the body.
Here is my script:
chars_available = 160 - 39 - len(subject) - len(to) # the 39 is for
the length of the sender address, header labels, etc.
if chars_available < 0:
chars_available = 0
message = mail.EmailMessage(
sender = "[email protected]", # shorten your from address. This
requires a new GAE admin acccount
subject = subject,
body = body[:chars_available],
to = to
)
Would love to see a true SMS feature in GAE!
--
You received this message because you are subscribed to the Google Groups
"Google App Engine" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-appengine?hl=en.