Class: Lago::Api::Resources::Group
- Inherits:
-
Base
- Object
- Base
- Lago::Api::Resources::Group
show all
- Defined in:
- lib/lago/api/resources/group.rb
Instance Attribute Summary
Attributes inherited from Base
#client
Instance Method Summary
collapse
Methods inherited from Base
#create, #destroy, #get, #initialize, #update, #whitelist_params
Instance Method Details
#api_resource ⇒ Object
7
8
9
|
# File 'lib/lago/api/resources/group.rb', line 7
def api_resource
'groups'
end
|
#get_all(code, options = {}) ⇒ Object
15
16
17
18
19
20
|
# File 'lib/lago/api/resources/group.rb', line 15
def get_all(code, options = {})
path = "/api/v1/billable_metrics/#{code}/groups"
response = connection.get_all(options, path)
JSON.parse(response.to_json, object_class: OpenStruct)
end
|
#root_name ⇒ Object
11
12
13
|
# File 'lib/lago/api/resources/group.rb', line 11
def root_name
'group'
end
|