public static class SubscriptionListParams.Builder
extends java.lang.Object
| Constructor and Description |
|---|
Builder() |
| Modifier and Type | Method and Description |
|---|---|
SubscriptionListParams.Builder |
addAllExpand(java.util.List<java.lang.String> elements)
Add all elements to `expand` list.
|
SubscriptionListParams.Builder |
addExpand(java.lang.String element)
Add an element to `expand` list.
|
SubscriptionListParams |
build()
Finalize and obtain parameter instance from this builder.
|
SubscriptionListParams.Builder |
putAllExtraParam(java.util.Map<java.lang.String,java.lang.Object> map)
Add all map key/value pairs to `extraParams` map.
|
SubscriptionListParams.Builder |
putExtraParam(java.lang.String key,
java.lang.Object value)
Add a key/value pair to `extraParams` map.
|
SubscriptionListParams.Builder |
setCollectionMethod(SubscriptionListParams.CollectionMethod collectionMethod)
The collection method of the subscriptions to retrieve.
|
SubscriptionListParams.Builder |
setCreated(java.lang.Long created) |
SubscriptionListParams.Builder |
setCreated(SubscriptionListParams.Created created) |
SubscriptionListParams.Builder |
setCurrentPeriodEnd(java.lang.Long currentPeriodEnd) |
SubscriptionListParams.Builder |
setCurrentPeriodEnd(SubscriptionListParams.CurrentPeriodEnd currentPeriodEnd) |
SubscriptionListParams.Builder |
setCurrentPeriodStart(java.lang.Long currentPeriodStart) |
SubscriptionListParams.Builder |
setCurrentPeriodStart(SubscriptionListParams.CurrentPeriodStart currentPeriodStart) |
SubscriptionListParams.Builder |
setCustomer(java.lang.String customer)
The ID of the customer whose subscriptions will be retrieved.
|
SubscriptionListParams.Builder |
setEndingBefore(java.lang.String endingBefore)
A cursor for use in pagination.
|
SubscriptionListParams.Builder |
setLimit(java.lang.Long limit)
A limit on the number of objects to be returned.
|
SubscriptionListParams.Builder |
setPlan(java.lang.String plan)
The ID of the plan whose subscriptions will be retrieved.
|
SubscriptionListParams.Builder |
setPrice(java.lang.String price)
Filter for subscriptions that contain this recurring price ID.
|
SubscriptionListParams.Builder |
setStartingAfter(java.lang.String startingAfter)
A cursor for use in pagination.
|
SubscriptionListParams.Builder |
setStatus(SubscriptionListParams.Status status)
The status of the subscriptions to retrieve.
|
public SubscriptionListParams build()
public SubscriptionListParams.Builder setCollectionMethod(SubscriptionListParams.CollectionMethod collectionMethod)
charge_automatically
or send_invoice.public SubscriptionListParams.Builder setCreated(SubscriptionListParams.Created created)
public SubscriptionListParams.Builder setCreated(java.lang.Long created)
public SubscriptionListParams.Builder setCurrentPeriodEnd(SubscriptionListParams.CurrentPeriodEnd currentPeriodEnd)
public SubscriptionListParams.Builder setCurrentPeriodEnd(java.lang.Long currentPeriodEnd)
public SubscriptionListParams.Builder setCurrentPeriodStart(SubscriptionListParams.CurrentPeriodStart currentPeriodStart)
public SubscriptionListParams.Builder setCurrentPeriodStart(java.lang.Long currentPeriodStart)
public SubscriptionListParams.Builder setCustomer(java.lang.String customer)
public SubscriptionListParams.Builder setEndingBefore(java.lang.String endingBefore)
ending_before is an object ID that defines your place
in the list. For instance, if you make a list request and receive 100 objects, starting with
obj_bar, your subsequent call can include ending_before=obj_bar in order to
fetch the previous page of the list.public SubscriptionListParams.Builder addExpand(java.lang.String element)
SubscriptionListParams.expand for the field documentation.public SubscriptionListParams.Builder addAllExpand(java.util.List<java.lang.String> elements)
SubscriptionListParams.expand for the field documentation.public SubscriptionListParams.Builder putExtraParam(java.lang.String key, java.lang.Object value)
SubscriptionListParams.extraParams for the field documentation.public SubscriptionListParams.Builder putAllExtraParam(java.util.Map<java.lang.String,java.lang.Object> map)
SubscriptionListParams.extraParams for the field documentation.public SubscriptionListParams.Builder setLimit(java.lang.Long limit)
public SubscriptionListParams.Builder setPlan(java.lang.String plan)
public SubscriptionListParams.Builder setPrice(java.lang.String price)
public SubscriptionListParams.Builder setStartingAfter(java.lang.String startingAfter)
starting_after is an object ID that defines your
place in the list. For instance, if you make a list request and receive 100 objects, ending
with obj_foo, your subsequent call can include starting_after=obj_foo in
order to fetch the next page of the list.public SubscriptionListParams.Builder setStatus(SubscriptionListParams.Status status)
incomplete, incomplete_expired, trialing, active, past_due, unpaid,
canceled, or all. Passing in a value of canceled will return all
canceled subscriptions, including those belonging to deleted customers. Passing in a value of
all will return subscriptions of all statuses.