Module: Luminati::Client::Customer

Included in:
Luminati::Client
Defined in:
lib/luminati/client/customer.rb

Instance Method Summary collapse

Instance Method Details

#customer_balanceHash

Returns the total balance of your account.



21
22
23
# File 'lib/luminati/client/customer.rb', line 21

def customer_balance
  request(:get, "/api/customer/balance")
end

#customer_bandwidth_stats(from = nil, to = nil) ⇒ Hash

Returns the bandwidth stats for all your zones.

Parameters:

  • from (String) (defaults to: nil)

    This should be in the format ‘2018-07-01T00:00:00`.

  • to (String) (defaults to: nil)

    This should be in the format ‘2018-07-02T00:00:00`.

Returns:

  • (Hash)

See Also:



11
12
13
14
15
16
# File 'lib/luminati/client/customer.rb', line 11

def customer_bandwidth_stats(from = nil, to = nil)
  parameters = "details=1"
  parameters << "&from=#{from}" if from
  parameters << "&to=#{to}" if to
  request(:get, "/api/customer/bw?#{parameters}")
end