Class: Copyscape::Balance

Inherits:
RequestBase show all
Defined in:
lib/copyscape/balance.rb

Instance Method Summary collapse

Methods inherited from RequestBase

#base_params, #get_response, #post_response, #response

Constructor Details

#initialize(format = :xml, options = {}) ⇒ Balance

Returns a new instance of Balance.



5
6
7
8
9
10
11
12
13
# File 'lib/copyscape/balance.rb', line 5

def initialize(format = :xml, options = {})
  options = {
    f: format.to_s,
    o: 'balance'
  }.merge(options)

  http_response = get_response(options)
  @response = Response.new(http_response)
end