0.6.6 • Published 2 years ago

@cisco/bot-commands v0.6.6

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
2 years ago

Bot commands

Create responsive bot commands with ease.

Installation

Install with npm.

npm i @gve/bot-commands

Usage

const { Command } = require("@gve/bot-commands");

const phrases = ["hello", "hi", "hey"];

class Hello extends Command {
  constructor(intent = "hello", config = { phrases }) {
    super(intent, config);
    this.handleText = this.sayHello.bind(this);
  }

  async sayHello(bot, message) {
    await bot.say("Hello 👋");
  }
}

License

Apache 2.0

0.6.6

2 years ago

0.6.5

2 years ago

0.6.3

2 years ago

0.6.2

2 years ago

0.6.4

2 years ago

0.6.1

2 years ago

0.6.0

2 years ago