Class: Mambu::Savings

Inherits:
ApiModel show all
Extended by:
Helpers
Defined in:
lib/mambu/savings.rb

Class Method Summary collapse

Methods included from Helpers

camelize_hash, handle_error

Methods inherited from ApiModel

api_uri, #convert_decimal, endpoint, #initialize

Constructor Details

This class inherits a constructor from Mambu::ApiModel

Class Method Details

.create_deposit(account_id, connection, data) ⇒ Object



5
6
7
8
9
10
11
12
# File 'lib/mambu/savings.rb', line 5

def self.create_deposit(, connection, data)
  response = connection.post(
    "#{endpoint(connection)}/#{}/transactions",
    camelize_hash(data)
  )
  handle_error(response)
  new(response.body)
end