Class: BancboxInvest
- Inherits:
-
Object
- Object
- BancboxInvest
- Defined in:
- lib/bancbox_invest.rb
Constant Summary collapse
- METHODS =
%w[create_investor submit_agreement verify_identity create_issuer create_escrow_account fund_account fund_escrow cge_investor_contr cancel_escrow close_escrow get_escrow_details get_escrow_list get_activity_details get_investor_list get_investor_details get_issuer_list get_issuer_details disburse_escrow disburse_escrow get_investment_ledger update_investment_ledger freeze_investment_ledger create_proceeds_schedules get_proceeds_schedules cancel_proceeds_schedules withdraw_funds update_escrow_account transfer_funds link_external_account confirm_wire_transfer verify_income accredit_investor_3rd_party get_verification_status get_activity get_ledger create_challenge_deposit verify_challenge_deposit get_challenge_deposit_status update_investor update_issuer]
Instance Attribute Summary collapse
-
#bancbox_api_key ⇒ Object
Returns the value of attribute bancbox_api_key.
-
#bancbox_api_secret ⇒ Object
Returns the value of attribute bancbox_api_secret.
-
#bancbox_api_url ⇒ Object
Returns the value of attribute bancbox_api_url.
Instance Method Summary collapse
- #credentials ⇒ Object
-
#initialize(options = {}) {|_self| ... } ⇒ BancboxInvest
constructor
A new instance of BancboxInvest.
- #post(url, options) ⇒ Object
Constructor Details
#initialize(options = {}) {|_self| ... } ⇒ BancboxInvest
Returns a new instance of BancboxInvest.
16 17 18 19 20 21 22 |
# File 'lib/bancbox_invest.rb', line 16 def initialize( = {}) .each do |key, value| send(:"#{key}=", value) end yield(self) if block_given? @options = credentials end |
Instance Attribute Details
#bancbox_api_key ⇒ Object
Returns the value of attribute bancbox_api_key.
6 7 8 |
# File 'lib/bancbox_invest.rb', line 6 def bancbox_api_key @bancbox_api_key end |
#bancbox_api_secret ⇒ Object
Returns the value of attribute bancbox_api_secret.
6 7 8 |
# File 'lib/bancbox_invest.rb', line 6 def bancbox_api_secret @bancbox_api_secret end |
#bancbox_api_url ⇒ Object
Returns the value of attribute bancbox_api_url.
6 7 8 |
# File 'lib/bancbox_invest.rb', line 6 def bancbox_api_url @bancbox_api_url end |
Instance Method Details
#credentials ⇒ Object
24 25 26 27 28 29 |
# File 'lib/bancbox_invest.rb', line 24 def credentials { api_key: bancbox_api_key, secret: bancbox_api_secret, } end |
#post(url, options) ⇒ Object
31 32 33 |
# File 'lib/bancbox_invest.rb', line 31 def post(url, ) HTTParty.post(bancbox_api_url+url, query: ) end |