Skip to content

Commit

Permalink
Codegen for openapi v190 (#1435)
Browse files Browse the repository at this point in the history
  • Loading branch information
yejia-stripe committed Sep 9, 2022
1 parent 24fd743 commit abfacb7
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 2 deletions.
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v189
v190
2 changes: 1 addition & 1 deletion src/main/java/com/stripe/model/Invoice.java
Original file line number Diff line number Diff line change
Expand Up @@ -522,7 +522,7 @@ public class Invoice extends ApiResource implements HasId, MetadataStore<Invoice

/** The aggregate amounts calculated per discount across all line items. */
@SerializedName("total_discount_amounts")
List<DiscountAmount> totalDiscountAmounts;
List<Invoice.DiscountAmount> totalDiscountAmounts;

/**
* The integer amount in %s representing the total amount of the invoice including all discounts
Expand Down
8 changes: 8 additions & 0 deletions src/main/java/com/stripe/model/issuing/Card.java
Original file line number Diff line number Diff line change
Expand Up @@ -387,6 +387,14 @@ public static class Shipping extends StripeObject {
@SerializedName("phone_number")
String phoneNumber;

/**
* Whether a signature is required for card delivery. This feature is only supported for US
* users. Standard shipping service does not support signature on delivery. The default value
* for standard shipping service is false and for express and priority services is true.
*/
@SerializedName("require_signature")
Boolean requireSignature;

/**
* Shipment service, such as {@code standard} or {@code express}.
*
Expand Down
15 changes: 15 additions & 0 deletions src/main/java/com/stripe/param/issuing/CardCreateParams.java
Original file line number Diff line number Diff line change
Expand Up @@ -319,6 +319,10 @@ public static class Shipping {
@SerializedName("phone_number")
String phoneNumber;

/** Whether a signature is required for card delivery. */
@SerializedName("require_signature")
Boolean requireSignature;

/** Shipment service. */
@SerializedName("service")
Service service;
Expand All @@ -333,13 +337,15 @@ private Shipping(
Map<String, Object> extraParams,
String name,
String phoneNumber,
Boolean requireSignature,
Service service,
Type type) {
this.address = address;
this.customs = customs;
this.extraParams = extraParams;
this.name = name;
this.phoneNumber = phoneNumber;
this.requireSignature = requireSignature;
this.service = service;
this.type = type;
}
Expand All @@ -359,6 +365,8 @@ public static class Builder {

private String phoneNumber;

private Boolean requireSignature;

private Service service;

private Type type;
Expand All @@ -371,6 +379,7 @@ public Shipping build() {
this.extraParams,
this.name,
this.phoneNumber,
this.requireSignature,
this.service,
this.type);
}
Expand Down Expand Up @@ -425,6 +434,12 @@ public Builder setPhoneNumber(String phoneNumber) {
return this;
}

/** Whether a signature is required for card delivery. */
public Builder setRequireSignature(Boolean requireSignature) {
this.requireSignature = requireSignature;
return this;
}

/** Shipment service. */
public Builder setService(Service service) {
this.service = service;
Expand Down

0 comments on commit abfacb7

Please sign in to comment.