Class: FacebookCommerce::Api

Inherits:
Object
  • Object
show all
Defined in:
lib/facebook_commerce.rb

Defined Under Namespace

Classes: UnexpectedHttpResponse

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(config = super.config) ⇒ Api



35
36
37
38
39
# File 'lib/facebook_commerce.rb', line 35

def initialize(config = super.config)
  @cms_id = config.fetch(:cms_id)
  @access_token = config.fetch(:access_token)
  @logger = config[:logger] || Logger.new(STDOUT)
end

Instance Attribute Details

#access_tokenObject (readonly)



29
30
31
# File 'lib/facebook_commerce.rb', line 29

def access_token
  @access_token
end

#cms_idObject (readonly)

Returns the value of attribute cms_id.



30
31
32
# File 'lib/facebook_commerce.rb', line 30

def cms_id
  @cms_id
end

#loggerObject

Returns the value of attribute logger.



31
32
33
# File 'lib/facebook_commerce.rb', line 31

def logger
  @logger
end