Forum Discussion
JimOwen-707d222
2 years agoCommunity Member
Thanks, that fixed the sample code, one step closer...
Now, the actual code is not running, so something is wrong there too. Here is the actual code I'm trying to run. It uses Twilio to send me a text message every time someone opens my project. Any idea what's happening here?
I got this code from here:
https://www.twilio.com/blog/2016/04/send-text-in-javascript-node-in-30-seconds.html
var twilio = require('twilio');
var player=GetPlayer();
player.SetVar("varRandom", Math.floor((Math.random()*1000)+1));
//alert("It is" + player.GetVar("varRandom"));
var client = new twilio('redacted', 'redacted');
client.messages.create({
to: '+12065016936',
from: '+14065016936',
body: player.GetVar("varRandom") + ' Splash screen'
});