has anyone found an sms messenger app or widget that is scriptable? i've been looking and can't seem to find one. i'd like to setup sending text messages to cell phones....
any info is appreciated, tia.
-- You need to add an account to your buddy list with
-- your mobile number.
property mobileNumber : "+18005551212"
on SendSMS(message)
tell application "iChat"
activate
if status is offline then
log in of service "AIM"
end if
send message to account mobileNumber
end tell
end SendSMS
Paco wrote:Hey Lalit, could you give more details about your installation ? Have you written an attachment script that would work like Ovolab Phlink one to use only one line instruction (MakeEmergencyCallToNumber) to call phones ?
tell application "IndigoServer"
if value of variable "TypeSms" is "texto" then set TypeSms to false
if value of variable "TypeSms" is "flash" then set TypeSms to true
set emetteur to value of variable "Emetteur"
if value of variable "Destinataire" is "monsieur" then set destinataire to "+336XXXXXXXX"
if value of variable "Destinataire" is "madame" then set destinataire to "+336XXXXXXXX"
set contenu to value of variable "Message"
end tell
tell application "SMS Mac Scripting"
set account to "xxxxxxxx"
set pin to "xxxx"
set sms to make new outgoing sms
tell sms
set flash to TypeSms
set delivery report to true
set sender to {emetteur}
set recipients to {destinataire}
set message to contenu
my envoiSms()
end tell
end tell
on envoiSms()
tell application "SMS Mac Scripting"
send outgoing sms 1
set textoRestants to balance
end tell
delay 1
tell application "IndigoServer"
set value of variable "SmsRestants" to textoRestants
set value of variable "TypeSms" to ""
set value of variable "Emetteur" to ""
set value of variable "Destinataire" to ""
set value of variable "Message" to ""
end tell
end envoiSms
tell application "IndigoServer"
set value of variable "TypeSms" to "flash" -- or "texto" as you want
set value of variable "Emetteur" to "Indigo"
set value of variable "Destinataire" to "monsieur"
set value of variable "Message" to ":-( Blablabla" -- SMSMac support smileys !
execute script "/:Library:Application Support:Perceptive Automation:Indigo 2:Scripts:SMS.scpt"
end tell
using terms from application "IndigoServer"
on receive security event of evenement with code dispositifID
---blabla---
if evenement is sec_SensorNormal_min then detecteurVeille_min(dispositifID)
if evenement is sec_SensorNormal_max then detecteurVeille_max(dispositifID)
if evenement is sec_SensorAlert_min then detecteurAlerte_min(dispositifID)
if evenement is sec_SensorAlert_max then detecteurAlerte_max(dispositifID)
---blabla---
end receive security event
on detecteurAlerte_min(dispositifID)
if dispositifID = 110 then --
my sms("texto", "ALARME", "monsieur", ":-( L'alarme a été déclenchée par la porte d'entrée ! Blablabla...")
end if
if dispositifID = 82 then --
my sms("texto", "ALARME", "monsieur", ":-( L'alarme a été déclenchée par la fenêtre ! Blablabla...")
end if
end detecteurAlerte_min
-- at the end of the script
on sms(smsType, emetteur, destinataire, contenu)
set value of variable "TypeSms" to smsType
set value of variable "Emetteur" to emetteur
set value of variable "Destinataire" to destinataire
set value of variable "Message" to contenu
execute script "/:Library:Application Support:Perceptive Automation:Indigo 2:Scripts:SMS.scpt"
end sms
end using terms from
Users browsing this forum: No registered users and 4 guests