Class: Cobrato::Resources::CreditCard

Inherits:
Base
  • Object
show all
Defined in:
lib/cobrato/resources/credit_card.rb

Instance Attribute Summary

Attributes inherited from Base

#http

Instance Method Summary collapse

Methods inherited from Base

#collection_name, #create, crud, #destroy, #initialize, #list, #parsed_body, #show, #update

Methods included from Hooks

#notify

Constructor Details

This class inherits a constructor from Cobrato::Resources::Base

Instance Method Details

#charges(id, params = {}) ⇒ Object



6
7
8
9
10
# File 'lib/cobrato/resources/credit_card.rb', line 6

def charges(id, params={})
  http.get("#{resource_base_path}/#{id}/charges", params: params) do |response|
    respond_with_collection(response, "Charge")
  end
end