-
-
Save gayanhewa/32886d4e14b500a02e82 to your computer and use it in GitHub Desktop.
SMSGateway.me
This file contains 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
BroadcastSMS = function(message, phonenumber) { | |
// Depends on smsgateway.me API v2. Sends sms via Android Device. Not a typical SMS gateway. | |
var URL = 'http://v2.smsgateway.me/API/Send/Single.php?Username='+Config.sms_gateway_username+'&Password='+Config.sms_gateway_password+'&Message='+message+'&Number='+phonenumber; | |
console.log(URL); | |
try{ | |
res = Meteor.http.get(URL); | |
if (res && res.Success == true) { | |
//console.log('Success') | |
//console.log(res); | |
return true; | |
} | |
}catch(e){ | |
console.log('Error occured while sending sms.'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment