Class: FloopFloop::Usage

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

Instance Method Summary collapse

Constructor Details

#initialize(client) ⇒ Usage

Returns a new instance of Usage.



5
6
7
# File 'lib/floopfloop/usage.rb', line 5

def initialize(client)
  @client = client
end

Instance Method Details

#summaryObject

Returns the full { “plan” => …, “credits” => …, “currentPeriod” => … } hash. Not wrapped in a struct — stays forward-compatible if the backend adds fields.



12
13
14
# File 'lib/floopfloop/usage.rb', line 12

def summary
  @client.request("GET", "/api/v1/usage/summary")
end