Skip to content

Instantly share code, notes, and snippets.

@ihciah
Created September 19, 2018 05:46
Show Gist options
  • Save ihciah/218c1f770d4e0a9bd4666a5f593977d9 to your computer and use it in GitHub Desktop.
Save ihciah/218c1f770d4e0a9bd4666a5f593977d9 to your computer and use it in GitHub Desktop.
Forward SMS using Tasker
var SMS = global('SMSRB');
var SENDER = global('SMSRF');
var SMSCONTENT = SMS + "\nSender: " + SENDER + "\nFrom Mobile"
var url = "https://xxxxxxxx/sendMessage?chat_id=0000000";
var xhttp = new XMLHttpRequest();
xhttp.open("POST", url, false);
xhttp.setRequestHeader("Content-type","application/x-www-form-urlencoded");
xhttp.send("text="+encodeURIComponent(SMSCONTENT));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment