public async Task <XCommasResponse <Deal[]> > GetDealsAsync(int limit = 50, int?offset = null, int?accountId = null, int?botId = null, DealScope dealScope = DealScope.All, DealOrder dealOrder = DealOrder.CreatedAt) { var path = $"{BaseAddress}/ver1/deals?limit={limit}&offset={offset}&account_id={accountId}&bot_id={botId}&scope={dealScope.GetEnumMemberAttrValue()}&order={dealOrder.GetEnumMemberAttrValue()}"; using (var request = XCommasRequest.Get(path).Sign(this)) { return(await this.GetResponse <Deal[]>(request).ConfigureAwait(false)); } }
public XCommasResponse <Deal[]> GetDeals(int limit = 50, int?offset = null, int?accountId = null, int?botId = null, DealScope dealScope = DealScope.All, DealOrder dealOrder = DealOrder.CreatedAt) => this.GetDealsAsync(limit, offset, accountId, botId, dealScope, dealOrder).Result;