A .NET Framework class library written to provide quick access to methods that communicate with a server that has a CloudCoin Wallet with CloudBank enabled, in order to create applications that can use CloudCoins.
Create a BankKeys object that contains the keys to the CloudService server you wish to connect to, then create an instance of the class CloudBankUtils using that BankKeys. Call CloudBankUtils' methods to communicate with the CloudService.
An Example application that can be used to test this SDK can be found here: https://github.com/CloudCoinConsortium/CloudBankTester
Newtonsoft.Json is used to Deserialize http responses sent in json format.
CloudBankUtils(BankKeys startKeys) CloudBankUtils(BankKeys startKeys, HttpClient client)
BankKeys are an object that contain url, privatekey, and account Strings. The keys for your cloudbank are created and saved to a json format text file when you enable cloudbank on your cloudcoin wallet. If you decide not to provide a HttpClient for the CloudBankUtils to use, then the constructor will create an instance for itself.
Calls the CloudBank's show_coins service for the server that this object holds the keys for. The results are saved in this class's public properties: onesInBank, fivesInBank, twentyfivesInBank, hundredsInBank, twohundredfiftiesInBank.
Calls the echo service from the CloudBank server that this object holds the keys for. The response's message is sent to console.out
Calls the print_welcome service from the CloudBank server that this object holds the keys for. The response's message is sent to console.out
Sets private field rawStackForDeposit to a CloudCoin stack read from a file found in parameter filepath This needs to be run before using some this classes other methods.
Sends the CloudCoin in private field rawStackForDeposit to the CloudBank server that this object holds the keys for An optional note or memo is sent as well loadStackFromFile needs to be called first
Sends the CloudCoin in private field rawStackForDeposit to the CloudBank server specified by toPublicUrl An optional note or memo is sent as well loadStackFromFile needs to be called first
Retrieve the receipt generated by the CloudBank for the last call that sends back a receipt id Requires sendStackToCloudBank, or one of the Skywallet functions to have been previously called The retrieved receipt will be saved in private field rawReceipt
Retrieves a CloudCoin stack file from the CloudBank server that this object holds the keys for. The resulting stack that is retrieved is saved in private field rawStackFromWithdrawal
This this will make the CloudBank send CloudCoins from the local wallet saved in the CloudBank to a Skywallet Account.Specify the amount to be sent. The CloudBank will make change if necessary. The address of the skywallet you are sending coins to should be in [name].skywallet.cc format
Downloads all the coin in the Skywallet set in your CloudBank's settings to the CloudBank's local wallet. This is will return that the process has started but not the results.\
Sends Coins from the skywallet set in your CloudBank's settings to another specified Skywallet
Parses pertinent information from the receipt last gathered by getReceipt and returns it in the form of an Interpretation object the only function that allows public access to receipt data
Writes a CloudCoin stack file for the CloudCoin retrieved the last call of either getStackFromCloudBank or a skywallet function and saved in rawStackFromWithdrawal