require 'opal' require 'native' `const Botkit = require('botkit');` token="[APIトークン]" controller = Native(`Botkit.slackbot()`) controller.spawn({ "token" => token }).startRTM do |err| if err exit end end controller.hears('hi', ['direct_message', 'direct_mention', 'mention'], Proc.new do |bot, msg| Native(`bot`).reply(msg, 'hi') end) ~