Browse Source

Merge branch 'feat/growi-bot' into imprv/refactor-bolt-service

yusuketk 5 years ago
parent
commit
59d87e9a91
1 changed files with 8 additions and 0 deletions
  1. 8 0
      src/server/service/bolt.js

+ 8 - 0
src/server/service/bolt.js

@@ -63,6 +63,14 @@ class BoltService {
     this.bolt.command('/growi-bot', async({ command, ack, say }) => { // demo
       await say('Hello');
     });
+
+    // The echo command simply echoes on command
+    this.bolt.command('/echo', async({ command, ack, say }) => {
+      // Acknowledge command request
+      await ack();
+
+      await say(`${command.text}`);
+    });
   }
 
 }