public async Task <YiimpWallet> WalletStatus(string wallet) { YiimpWallet walletSimple = new YiimpWallet(); string command = string.Format("{0}wallet?address={1}", apiUrl, wallet); string results = await GetPublicDataJson(command); walletSimple = JsonConvert.DeserializeObject <YiimpWallet>(results); return(walletSimple); }
protected void WalletRefresher() { do { try { wallet = api.WalletStatus(details.walletId).Result; Thread.Sleep(Switchster.WALLET_REFRESHER_DELAY); } catch { System.Console.Error.WriteLine("Failed to refresh balance data for {0}. Retrying in {1} seconds.", details.name, Switchster.RETRY_DELAY / Switchster.SECOND); Thread.Sleep(Switchster.RETRY_DELAY); } } while (Switchster.ALIVE); }