1.0.2 • Published 8 years ago

tk104-reply v1.0.2

Weekly downloads
3
License
MIT
Repository
github
Last release
8 years ago

TK104 - Reply

Just a simple wrapper to reply to TK104 SMS

var tk = require('./tk104-reply')([
  {
    "regex": /^sms ok/i,
    "reply": function() {
      return function(pwd) {
        return "sleep" + pwd + " deepshock";
      }
    },
  },
  {
    "regex": /^sleep deep ok/i,
    "reply": false
  }
]);

var message = tk.reply("SMS OK!")(123456); // 'sleep123456 deepshock'
var stop = tk.reply("sleep deep ok");      // false
1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago