Module: Paymill::Operations::Find::ClassMethods

Defined in:
lib/paymill/operations/find.rb

Instance Method Summary collapse

Instance Method Details

#find(id) ⇒ Paymill::Base

Finds a given object

Parameters:

  • id (Integer)

    The id of the object that should be found

Returns:



9
10
11
12
# File 'lib/paymill/operations/find.rb', line 9

def find(id)
  response = Paymill.request(:get, "#{self.name.split("::").last.downcase}s/#{id}", {})
  self.new(response["data"])
end