Skip to content

Commit 959d817

Browse files
committed
Add changes related to API version 2018-08-23
* add support for `tax_info` and `tax_info_verification` on Customer * add support for `unit_amount` on Tier and deprecate `amount`
1 parent 8536100 commit 959d817

File tree

2 files changed

+39
-2
lines changed

2 files changed

+39
-2
lines changed

Diff for: src/main/java/com/stripe/model/Customer.java

+28-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ public class Customer extends ApiResource implements MetadataStore<Customer>, Ha
1818
@Getter(onMethod = @__({@Override})) String id;
1919
String object;
2020
Long accountBalance;
21-
String businessVatId;
2221
Long created;
2322
String currency;
2423
@Getter(AccessLevel.NONE) @Setter(AccessLevel.NONE)
@@ -33,6 +32,18 @@ public class Customer extends ApiResource implements MetadataStore<Customer>, Ha
3332
ShippingDetails shipping;
3433
ExternalAccountCollection sources;
3534
CustomerSubscriptionCollection subscriptions;
35+
TaxInfo taxInfo;
36+
TaxInfoVerification taxInfoVerification;
37+
38+
/**
39+
* The {@code businessVatId} attribute.
40+
*
41+
* @return the {@code businessVatId} attribute
42+
* @deprecated Prefer using the {@link #taxInfo} attribute instead.
43+
* @see <a href="https://stripe.com/docs/upgrades#2018-08-23">API version 2018-08-23</a>
44+
*/
45+
@Deprecated
46+
String businessVatId;
3647

3748
/**
3849
* The {@code cards} attribute.
@@ -222,4 +233,20 @@ public static class NextRecurringCharge extends StripeObject {
222233
Long amount;
223234
String date;
224235
}
236+
237+
@Getter
238+
@Setter
239+
@EqualsAndHashCode(callSuper = false)
240+
public static class TaxInfo extends StripeObject {
241+
String taxId;
242+
String type;
243+
}
244+
245+
@Getter
246+
@Setter
247+
@EqualsAndHashCode(callSuper = false)
248+
public static class TaxInfoVerification extends StripeObject {
249+
String status;
250+
String verifiedName;
251+
}
225252
}

Diff for: src/main/java/com/stripe/model/Plan.java

+11-1
Original file line numberDiff line numberDiff line change
@@ -193,8 +193,18 @@ public Plan update(Map<String, Object> params, RequestOptions options) throws St
193193
@Setter
194194
@EqualsAndHashCode(callSuper = false)
195195
public static class Tier extends StripeObject {
196-
Long amount;
196+
Long unitAmount;
197197
Long upTo;
198+
199+
/**
200+
* The {@code amount} attribute.
201+
*
202+
* @return the {@code amount} attribute
203+
* @deprecated Prefer using the {@code unitAmount} attribute instead.
204+
* @see <a href="https://stripe.com/docs/upgrades#2018-08-23">API version 2018-08-23</a>
205+
*/
206+
@Deprecated
207+
Long amount;
198208
}
199209

200210
@Getter

0 commit comments

Comments
 (0)