Beispiel #1
0
 /// <inheritdoc />
 public async Task <AccountBalance> GetAccountBalanceAsync(NanoAccount account)
 {
     return(await PostActionAsync <AccountBalance>(new
     {
         Account = account.Account,
         Action = ActionTypes.AccountBalance
     }));
 }
Beispiel #2
0
 /// <inheritdoc/>
 public async Task <PublicKey> GetAccountPublicKeyAsync(NanoAccount account)
 {
     return(await PostActionAsync <PublicKey>(new
     {
         Action = ActionTypes.AccountKey,
         Account = account.Account
     }));
 }
Beispiel #3
0
 /// <inheritdoc />
 public async Task <AccountHistory> GetAccountHistoryAsync(NanoAccount account, int count)
 {
     return(await PostActionAsync <AccountHistory>(new
     {
         Action = ActionTypes.AccountHistory,
         Account = account.Account,
         Count = count
     }));
 }
Beispiel #4
0
 public async Task <BlockResponse> ReceiveAsync(NanoWallet wallet, NanoAccount nanoAccount, string block)
 {
     return(await PostActionAsync <BlockResponse>(new
     {
         Action = ActionTypes.Receive,
         Wallet = wallet.Wallet,
         Account = nanoAccount.Account,
         Block = block
     }));
 }
Beispiel #5
0
 /// <inheritdoc />
 public async Task <AccountInformationResponse> GetAccountInformationAsync(NanoAccount account, bool fetchRepresentative = false, bool fetchWeight = false, bool fetchPending = false)
 {
     return(await PostActionAsync <AccountInformationResponse>(new
     {
         Account = account.Account,
         Action = ActionTypes.AccountInfo,
         Pending = fetchPending,
         Weight = fetchWeight,
         Representative = fetchRepresentative
     }));
 }
Beispiel #6
0
 /// <inheritdoc />
 public async Task <BlockResponse> SendAsync(NanoWallet wallet, NanoAccount sourceAddress, NanoAccount destinationAddress, NanoAmount amount)
 {
     return(await PostActionAsync <BlockResponse>(new
     {
         Action = ActionTypes.Send,
         Wallet = wallet.Wallet,
         Source = sourceAddress.Account,
         Destination = destinationAddress.Account,
         Amount = amount.Raw
     }));
 }