/// <summary> /// Asynchronously gets transactions by range. /// </summary> /// /// <param name="req">The range paramters.</param> /// /// <returns>Returns an <see cref="Task{ArkTransactionList}"/> type.</returns> /// public async Task <ArkTransactionList> GetTransactionsAsync(ArkTransactionRequest req) { try { _logger.Info(string.Format("Getting transactions with filter <<{0}>>", req.ToQuery())); var response = await _networkApi.ActivePeer.MakeRequest(ArkStaticStrings.ArkHttpMethods.GET, string.Format(ArkStaticStrings.ArkApiPaths.Transaction.GET_ALL + "{0}", req.ToQuery())).ConfigureAwait(false); return(JsonConvert.DeserializeObject <ArkTransactionList>(response)); } catch (Exception e) { _logger.Error(e.ToString()); throw e; } }
public async static Task <ArkTransactionList> GetTransactionsAsync(ArkTransactionRequest req) { var response = await NetworkApi.Instance.ActivePeer.MakeRequest(ArkStaticStrings.ArkHttpMethods.GET, string.Format(ArkStaticStrings.ArkApiPaths.Transaction.GET_ALL + "{0}", req.ToQuery())); return(JsonConvert.DeserializeObject <ArkTransactionList>(response)); }
public static ArkTransactionList GetTransactions(ArkTransactionRequest req) { return(GetTransactionsAsync(req).Result); }