Sha256: 9c8fbbedff025b3704ce9e8dde9771719f41ad94076af6398adb6f4c02075a6e

Contents?: true

Size: 421 Bytes

Versions: 7

Compression:

Stored size: 421 Bytes

Contents

require 'net/http'
require 'cgi'

class EziiIntegration < ApplicationRecord

    def start
        require 'discordrb'

        bot = Discordrb::Bot.new token: ENV["DISCORD_TOKEN"]

        bot.message do |event|
            response_message = Net::HTTP.get('ezii-server.herokuapp.com', '/?message=' + CGI.escape(event.message.content))
            event.respond response_message
        end

        bot.run
    end
end

Version data entries

7 entries across 7 versions & 2 rubygems

Version Path
jester-data-8.0.0 app/models/ezii_integration.rb
ezii-os-5.2.1 app/models/ezii_integration.rb
ezii-os-2.0.1 app/models/ezii_integration.rb
ezii-os-1.1.0 app/models/ezii_integration.rb
ezii-os-1.0.0 app/models/ezii_integration.rb
ezii-os-0.0.0.1.0 app/models/ezii_integration.rb
ezii-os-0.0.0.0.1 app/models/ezii_integration.rb