public virtual StripeList <StripeSubscription> List(StripeSubscriptionListOptions listOptions = null, StripeRequestOptions requestOptions = null) { return(Mapper <StripeList <StripeSubscription> > .MapFromJson( Requestor.GetString(this.ApplyAllParameters(listOptions, Urls.Subscriptions, true), SetupRequestOptions(requestOptions)) )); }
public virtual async Task <StripeList <StripeSubscription> > ListAsync(StripeSubscriptionListOptions listOptions = null, StripeRequestOptions requestOptions = null, CancellationToken cancellationToken = default(CancellationToken)) { return(Mapper <StripeList <StripeSubscription> > .MapFromJson( await Requestor.GetStringAsync(this.ApplyAllParameters(listOptions, Urls.Subscriptions, true), SetupRequestOptions(requestOptions), cancellationToken) )); }
public virtual Task <StripeList <StripeSubscription> > ListAsync(string customerId, StripeListOptions listOptions = null, StripeRequestOptions requestOptions = null, CancellationToken cancellationToken = default(CancellationToken)) { var options = new StripeSubscriptionListOptions { CustomerId = customerId }; if (listOptions != null) { options.EndingBefore = listOptions.EndingBefore; options.StartingAfter = listOptions.StartingAfter; options.Limit = listOptions.Limit; } return(this.ListAsync(options, requestOptions, cancellationToken)); }
public virtual StripeList <StripeSubscription> List(string customerId, StripeListOptions listOptions = null, StripeRequestOptions requestOptions = null) { var options = new StripeSubscriptionListOptions { CustomerId = customerId }; if (listOptions != null) { options.EndingBefore = listOptions.EndingBefore; options.StartingAfter = listOptions.StartingAfter; options.Limit = listOptions.Limit; } return(this.List(options, requestOptions)); }