zcatalyst-cli
Version:
Command Line Tool for CATALYST
15 lines (11 loc) • 461 B
JavaScript
;
import Cliq from 'zcatalyst-integ-cliq';
const messageActionHandler = Cliq.messageAction();
messageActionHandler.executionHandler(async (req, res) => {
let text = '';
const msgType = req.message.type;
text = `Hey ${req.user ? req.user.first_name : 'user'}, You have performed an action on a *${msgType}*. `
+ 'Manipulate the message variable and perform your own action.';
res.setText(text);
return res;
});