Class: Squarespace::Config

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(options) ⇒ Config

Returns a new instance of Config.



5
6
7
8
9
10
11
# File 'lib/squarespace/configuration.rb', line 5

def initialize(options)
  @api_url = options[:api_url] || "https://api.squarespace.com"

  # No default values
  @app_name = options[:app_name]
  @api_key = options[:api_key]
end

Instance Attribute Details

#api_keyObject (readonly)

Returns the value of attribute api_key.



3
4
5
# File 'lib/squarespace/configuration.rb', line 3

def api_key
  @api_key
end

#api_urlObject (readonly)

Returns the value of attribute api_url.



3
4
5
# File 'lib/squarespace/configuration.rb', line 3

def api_url
  @api_url
end

#app_nameObject (readonly)

Returns the value of attribute app_name.



3
4
5
# File 'lib/squarespace/configuration.rb', line 3

def app_name
  @app_name
end