class CustomerxTracking::Base

Public Instance Methods

authorizations_is_not_present?() click to toggle source
# File lib/customerx_tracking/base.rb, line 7
def authorizations_is_not_present?
  ::CustomerxTracking.credential.nil? || ::CustomerxTracking.key.nil?
end
connection() click to toggle source
# File lib/customerx_tracking/base.rb, line 3
def connection
  @connection ||= Faraday.new(faraday_options)
end

Private Instance Methods

faraday_options() click to toggle source
# File lib/customerx_tracking/base.rb, line 13
def faraday_options
  {
    headers: {
      'Content-Type' => 'application/json',
      'credential' => CustomerxTracking.credential,
      'key'=> CustomerxTracking.key
    },
    url: ::CustomerxTracking.base_url
  }
end