class Besepa::BusinessAccount

Constants

FIELDS

Public Class Methods

default() click to toggle source
# File lib/besepa/business_account.rb, line 29
def self.default
  response = get "#{api_path}/default"
  self.new(response['response'])
end
klass_name() click to toggle source
# File lib/besepa/business_account.rb, line 19
def self.klass_name
  "bank_account"
end

Protected Class Methods

api_path(filters={}) click to toggle source
# File lib/besepa/business_account.rb, line 47
def self.api_path(filters={})
  "/account/bank_accounts"
end

Public Instance Methods

activation_request() click to toggle source
# File lib/besepa/business_account.rb, line 34
def activation_request
  response = put "#{api_path}/activation_request"
  process_attributes(response['response'])
  self
end
set_as_default() click to toggle source
# File lib/besepa/business_account.rb, line 23
def set_as_default
  response = put "#{api_path}/set_as_default"
  process_attributes(response['response'])
  self
end
stats() click to toggle source
# File lib/besepa/business_account.rb, line 40
def stats
  response = get "#{api_path}/stats"
  response['response']
end

Protected Instance Methods

api_path(filters={}) click to toggle source
# File lib/besepa/business_account.rb, line 51
def api_path(filters={})
  "/account/bank_accounts/#{CGI.escape(id)}"
end