class StarkitBanking::RBL::Account::GetBalance
Private Instance Methods
credentials(payment_account)
click to toggle source
# File lib/starkit_banking/api/rbl/account/balance.rb, line 21 def credentials(payment_account) payment_account.credentials end
invoke(env, req, callbacks)
click to toggle source
# File lib/starkit_banking/api/rbl/account/balance.rb, line 13 def invoke(env, req, callbacks) ApiBanking::GetAccountBalance.get_account_balance(env, req, callbacks) end
request(subscription, payment_account)
click to toggle source
# File lib/starkit_banking/api/rbl/account/balance.rb, line 25 def request(subscription, payment_account) header = ApiBanking::GetAccountBalance::ReqHeader.new() reqBody = ApiBanking::GetAccountBalance::ReqBody.new() request = ApiBanking::GetAccountBalance::Request.new() header.corpID = subscription.app_id header.approverID = payment_account.created_by reqBody.accountNo = payment_account.account_number request.header = header request.body = reqBody request end
response(rep)
click to toggle source
# File lib/starkit_banking/api/rbl/account/balance.rb, line 17 def response(rep) rep.balanceAmount end
service_name()
click to toggle source
# File lib/starkit_banking/api/rbl/account/balance.rb, line 9 def service_name 'BALANCE ENQUIRY' end
subscription(payment_account)
click to toggle source
# File lib/starkit_banking/api/rbl/account/balance.rb, line 42 def subscription(payment_account) payment_account.service_subscriptions.find_by(service_name: service_name) end