Class: CryptomateApi::Management::Configuration
- Defined in:
- lib/cryptomate_api/management/configuration.rb
Overview
Manage the company configurations from here, like changing the payment destination address for each blockchain.
Instance Method Summary collapse
-
#delete_payment_destination(blockchain) ⇒ Object
Delete payment destination Deletes the treasury wallet that all the payments will sent after being completed.
-
#get_payment_destination(blockchain) ⇒ Object
Get payment destination Gets the treasury wallet address for holding the payments received on the selected blockchain.
-
#set_payment_destination(address, blockchain) ⇒ Object
Set payment destination Sets the treasury wallet that all the payments will sent after being completed.
Methods inherited from Base
Constructor Details
This class inherits a constructor from CryptomateApi::Base
Instance Method Details
#delete_payment_destination(blockchain) ⇒ Object
Delete payment destination Deletes the treasury wallet that all the payments will sent after being completed. cryptomate.me/docs/management#delete-payment-destination Response: None
35 36 37 |
# File 'lib/cryptomate_api/management/configuration.rb', line 35 def delete_payment_destination(blockchain) self.class.delete("/management/configurations/payments/#{blockchain}") end |
#get_payment_destination(blockchain) ⇒ Object
Get payment destination Gets the treasury wallet address for holding the payments received on the selected blockchain. cryptomate.me/docs/management#get-payment-destination Response:
"address": "string",
"blockchain": "string"
16 17 18 |
# File 'lib/cryptomate_api/management/configuration.rb', line 16 def get_payment_destination(blockchain) self.class.get("/management/configurations/payments/#{blockchain}") end |
#set_payment_destination(address, blockchain) ⇒ Object
Set payment destination Sets the treasury wallet that all the payments will sent after being completed. cryptomate.me/docs/management#set-payment-destination Response: None
26 27 28 |
# File 'lib/cryptomate_api/management/configuration.rb', line 26 def set_payment_destination(address, blockchain) self.class.post('/management/configurations/payments', body: { address:, blockchain: }.to_json) end |