module Stengine
Constants
- VERSION
Public Class Methods
api_token()
click to toggle source
# File lib/stengine.rb, line 26 def self.api_token throw "Stengine's API Token was not found." if self.configuration.api_token.nil? return self.configuration.api_token end
configuration()
click to toggle source
# File lib/stengine.rb, line 18 def self.configuration @configuration ||= Configuration.new end
configure() { |configuration| ... }
click to toggle source
# File lib/stengine.rb, line 22 def self.configure yield(configuration) if block_given? end
event(event_name, model)
click to toggle source
# File lib/stengine.rb, line 31 def self.event(event_name, model) token = self.api_token Thread.new{ API.post("/events", body: { name: event_name, model: model, token: token }) } end