Skip to content

Commit

Permalink
Update generated code for v1258
Browse files Browse the repository at this point in the history
  • Loading branch information
stripe-openapi[bot] committed Sep 10, 2024
1 parent 00cfa52 commit d3532c0
Show file tree
Hide file tree
Showing 14 changed files with 796 additions and 35 deletions.
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v1257
v1258
70 changes: 36 additions & 34 deletions src/main/java/com/stripe/model/Event.java
Original file line number Diff line number Diff line change
Expand Up @@ -171,40 +171,42 @@ public class Event extends ApiResource implements HasId {
* issuing_dispute.closed}, {@code issuing_dispute.created}, {@code
* issuing_dispute.funds_reinstated}, {@code issuing_dispute.funds_rescinded}, {@code
* issuing_dispute.submitted}, {@code issuing_dispute.updated}, {@code
* issuing_personalization_design.activated}, {@code issuing_personalization_design.deactivated},
* {@code issuing_personalization_design.rejected}, {@code
* issuing_personalization_design.updated}, {@code issuing_token.created}, {@code
* issuing_token.updated}, {@code issuing_transaction.created}, {@code
* issuing_transaction.updated}, {@code mandate.updated}, {@code
* payment_intent.amount_capturable_updated}, {@code payment_intent.canceled}, {@code
* payment_intent.created}, {@code payment_intent.partially_funded}, {@code
* payment_intent.payment_failed}, {@code payment_intent.processing}, {@code
* payment_intent.requires_action}, {@code payment_intent.succeeded}, {@code
* payment_link.created}, {@code payment_link.updated}, {@code payment_method.attached}, {@code
* payment_method.automatically_updated}, {@code payment_method.detached}, {@code
* payment_method.updated}, {@code payout.canceled}, {@code payout.created}, {@code
* payout.failed}, {@code payout.paid}, {@code payout.reconciliation_completed}, {@code
* payout.updated}, {@code person.created}, {@code person.deleted}, {@code person.updated}, {@code
* plan.created}, {@code plan.deleted}, {@code plan.updated}, {@code price.created}, {@code
* price.deleted}, {@code price.updated}, {@code product.created}, {@code product.deleted}, {@code
* product.updated}, {@code promotion_code.created}, {@code promotion_code.updated}, {@code
* quote.accept_failed}, {@code quote.accepted}, {@code quote.accepting}, {@code quote.canceled},
* {@code quote.created}, {@code quote.draft}, {@code quote.finalized}, {@code
* quote.reestimate_failed}, {@code quote.reestimated}, {@code quote.stale}, {@code
* radar.early_fraud_warning.created}, {@code radar.early_fraud_warning.updated}, {@code
* refund.created}, {@code refund.updated}, {@code reporting.report_run.failed}, {@code
* reporting.report_run.succeeded}, {@code reporting.report_type.updated}, {@code review.closed},
* {@code review.opened}, {@code setup_intent.canceled}, {@code setup_intent.created}, {@code
* setup_intent.requires_action}, {@code setup_intent.setup_failed}, {@code
* setup_intent.succeeded}, {@code sigma.scheduled_query_run.created}, {@code source.canceled},
* {@code source.chargeable}, {@code source.failed}, {@code source.mandate_notification}, {@code
* source.refund_attributes_required}, {@code source.transaction.created}, {@code
* source.transaction.updated}, {@code subscription_schedule.aborted}, {@code
* subscription_schedule.canceled}, {@code subscription_schedule.completed}, {@code
* subscription_schedule.created}, {@code subscription_schedule.expiring}, {@code
* subscription_schedule.price_migration_failed}, {@code subscription_schedule.released}, {@code
* subscription_schedule.updated}, {@code tax.form.updated}, {@code tax.settings.updated}, {@code
* tax_rate.created}, {@code tax_rate.updated}, {@code terminal.reader.action_failed}, {@code
* issuing_dispute_settlement_detail.created}, {@code issuing_dispute_settlement_detail.updated},
* {@code issuing_personalization_design.activated}, {@code
* issuing_personalization_design.deactivated}, {@code issuing_personalization_design.rejected},
* {@code issuing_personalization_design.updated}, {@code issuing_settlement.created}, {@code
* issuing_settlement.updated}, {@code issuing_token.created}, {@code issuing_token.updated},
* {@code issuing_transaction.created}, {@code issuing_transaction.updated}, {@code
* mandate.updated}, {@code payment_intent.amount_capturable_updated}, {@code
* payment_intent.canceled}, {@code payment_intent.created}, {@code
* payment_intent.partially_funded}, {@code payment_intent.payment_failed}, {@code
* payment_intent.processing}, {@code payment_intent.requires_action}, {@code
* payment_intent.succeeded}, {@code payment_link.created}, {@code payment_link.updated}, {@code
* payment_method.attached}, {@code payment_method.automatically_updated}, {@code
* payment_method.detached}, {@code payment_method.updated}, {@code payout.canceled}, {@code
* payout.created}, {@code payout.failed}, {@code payout.paid}, {@code
* payout.reconciliation_completed}, {@code payout.updated}, {@code person.created}, {@code
* person.deleted}, {@code person.updated}, {@code plan.created}, {@code plan.deleted}, {@code
* plan.updated}, {@code price.created}, {@code price.deleted}, {@code price.updated}, {@code
* product.created}, {@code product.deleted}, {@code product.updated}, {@code
* promotion_code.created}, {@code promotion_code.updated}, {@code quote.accept_failed}, {@code
* quote.accepted}, {@code quote.accepting}, {@code quote.canceled}, {@code quote.created}, {@code
* quote.draft}, {@code quote.finalized}, {@code quote.reestimate_failed}, {@code
* quote.reestimated}, {@code quote.stale}, {@code radar.early_fraud_warning.created}, {@code
* radar.early_fraud_warning.updated}, {@code refund.created}, {@code refund.updated}, {@code
* reporting.report_run.failed}, {@code reporting.report_run.succeeded}, {@code
* reporting.report_type.updated}, {@code review.closed}, {@code review.opened}, {@code
* setup_intent.canceled}, {@code setup_intent.created}, {@code setup_intent.requires_action},
* {@code setup_intent.setup_failed}, {@code setup_intent.succeeded}, {@code
* sigma.scheduled_query_run.created}, {@code source.canceled}, {@code source.chargeable}, {@code
* source.failed}, {@code source.mandate_notification}, {@code source.refund_attributes_required},
* {@code source.transaction.created}, {@code source.transaction.updated}, {@code
* subscription_schedule.aborted}, {@code subscription_schedule.canceled}, {@code
* subscription_schedule.completed}, {@code subscription_schedule.created}, {@code
* subscription_schedule.expiring}, {@code subscription_schedule.price_migration_failed}, {@code
* subscription_schedule.released}, {@code subscription_schedule.updated}, {@code
* tax.form.updated}, {@code tax.settings.updated}, {@code tax_rate.created}, {@code
* tax_rate.updated}, {@code terminal.reader.action_failed}, {@code
* terminal.reader.action_succeeded}, {@code terminal.reader.action_updated}, {@code
* test_helpers.test_clock.advancing}, {@code test_helpers.test_clock.created}, {@code
* test_helpers.test_clock.deleted}, {@code test_helpers.test_clock.internal_failure}, {@code
Expand Down
4 changes: 4 additions & 0 deletions src/main/java/com/stripe/model/EventDataClassLookup.java
Original file line number Diff line number Diff line change
Expand Up @@ -167,9 +167,13 @@ final class EventDataClassLookup {
"issuing.credit_underwriting_record",
com.stripe.model.issuing.CreditUnderwritingRecord.class);
classLookup.put("issuing.dispute", com.stripe.model.issuing.Dispute.class);
classLookup.put(
"issuing.dispute_settlement_detail",
com.stripe.model.issuing.DisputeSettlementDetail.class);
classLookup.put(
"issuing.personalization_design", com.stripe.model.issuing.PersonalizationDesign.class);
classLookup.put("issuing.physical_bundle", com.stripe.model.issuing.PhysicalBundle.class);
classLookup.put("issuing.settlement", com.stripe.model.issuing.Settlement.class);
classLookup.put("issuing.token", com.stripe.model.issuing.Token.class);
classLookup.put("issuing.transaction", com.stripe.model.issuing.Transaction.class);

Expand Down
188 changes: 188 additions & 0 deletions src/main/java/com/stripe/model/issuing/DisputeSettlementDetail.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,188 @@
// File generated from our OpenAPI spec
package com.stripe.model.issuing;

import com.google.gson.annotations.SerializedName;
import com.stripe.exception.StripeException;
import com.stripe.model.HasId;
import com.stripe.net.ApiRequest;
import com.stripe.net.ApiRequestParams;
import com.stripe.net.ApiResource;
import com.stripe.net.BaseAddress;
import com.stripe.net.RequestOptions;
import com.stripe.param.issuing.DisputeSettlementDetailListParams;
import com.stripe.param.issuing.DisputeSettlementDetailRetrieveParams;
import java.util.Map;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.Setter;

/**
* Represents a record from the card network of a money movement or change in state for an Issuing
* dispute. These records are included in the settlement reports that we receive from networks and
* expose to users as Settlement objects.
*/
@Getter
@Setter
@EqualsAndHashCode(callSuper = false)
public class DisputeSettlementDetail extends ApiResource implements HasId {
/**
* Disputed amount in the card’s currency and in the smallest currency unit. Usually the amount of
* the transaction, but can differ (usually because of currency fluctuation).
*/
@SerializedName("amount")
Long amount;

/** The card used to make the original transaction. */
@SerializedName("card")
String card;

/** Time at which the object was created. Measured in seconds since the Unix epoch. */
@SerializedName("created")
Long created;

/**
* The currency the original transaction was made in. Three-letter <a
* href="https://www.iso.org/iso-4217-currency-codes.html">ISO currency code</a>, in lowercase.
* Must be a <a href="https://stripe.com/docs/currencies">supported currency</a>.
*/
@SerializedName("currency")
String currency;

/** The ID of the linked dispute. */
@SerializedName("dispute")
String dispute;

/**
* The type of event corresponding to this dispute settlement detail, representing the stage in
* the dispute network lifecycle.
*
* <p>One of {@code filing}, {@code loss}, {@code representment}, or {@code win}.
*/
@SerializedName("event_type")
String eventType;

/** Unique identifier for the object. */
@Getter(onMethod_ = {@Override})
@SerializedName("id")
String id;

/**
* Has the value {@code true} if the object exists in live mode or the value {@code false} if the
* object exists in test mode.
*/
@SerializedName("livemode")
Boolean livemode;

/**
* The card network for this dispute settlement detail. One of [&quot;visa&quot;,
* &quot;mastercard&quot;, &quot;maestro&quot;]
*/
@SerializedName("network")
String network;

/**
* String representing the object's type. Objects of the same type share the same value.
*
* <p>Equal to {@code issuing.dispute_settlement_detail}.
*/
@SerializedName("object")
String object;

/** The ID of the linked card network settlement. */
@SerializedName("settlement")
String settlement;

/**
* Returns a list of Issuing {@code DisputeSettlementDetail} objects. The objects are sorted in
* descending order by creation date, with the most recently created object appearing first.
*/
public static DisputeSettlementDetailCollection list(Map<String, Object> params)
throws StripeException {
return list(params, (RequestOptions) null);
}

/**
* Returns a list of Issuing {@code DisputeSettlementDetail} objects. The objects are sorted in
* descending order by creation date, with the most recently created object appearing first.
*/
public static DisputeSettlementDetailCollection list(
Map<String, Object> params, RequestOptions options) throws StripeException {
String path = "/v1/issuing/dispute_settlement_details";
ApiRequest request =
new ApiRequest(BaseAddress.API, ApiResource.RequestMethod.GET, path, params, options);
return getGlobalResponseGetter().request(request, DisputeSettlementDetailCollection.class);
}

/**
* Returns a list of Issuing {@code DisputeSettlementDetail} objects. The objects are sorted in
* descending order by creation date, with the most recently created object appearing first.
*/
public static DisputeSettlementDetailCollection list(DisputeSettlementDetailListParams params)
throws StripeException {
return list(params, (RequestOptions) null);
}

/**
* Returns a list of Issuing {@code DisputeSettlementDetail} objects. The objects are sorted in
* descending order by creation date, with the most recently created object appearing first.
*/
public static DisputeSettlementDetailCollection list(
DisputeSettlementDetailListParams params, RequestOptions options) throws StripeException {
String path = "/v1/issuing/dispute_settlement_details";
ApiResource.checkNullTypedParams(path, params);
ApiRequest request =
new ApiRequest(
BaseAddress.API,
ApiResource.RequestMethod.GET,
path,
ApiRequestParams.paramsToMap(params),
options);
return getGlobalResponseGetter().request(request, DisputeSettlementDetailCollection.class);
}

/** Retrieves an Issuing {@code DisputeSettlementDetail} object. */
public static DisputeSettlementDetail retrieve(String disputeSettlementDetail)
throws StripeException {
return retrieve(disputeSettlementDetail, (Map<String, Object>) null, (RequestOptions) null);
}

/** Retrieves an Issuing {@code DisputeSettlementDetail} object. */
public static DisputeSettlementDetail retrieve(
String disputeSettlementDetail, RequestOptions options) throws StripeException {
return retrieve(disputeSettlementDetail, (Map<String, Object>) null, options);
}

/** Retrieves an Issuing {@code DisputeSettlementDetail} object. */
public static DisputeSettlementDetail retrieve(
String disputeSettlementDetail, Map<String, Object> params, RequestOptions options)
throws StripeException {
String path =
String.format(
"/v1/issuing/dispute_settlement_details/%s",
ApiResource.urlEncodeId(disputeSettlementDetail));
ApiRequest request =
new ApiRequest(BaseAddress.API, ApiResource.RequestMethod.GET, path, params, options);
return getGlobalResponseGetter().request(request, DisputeSettlementDetail.class);
}

/** Retrieves an Issuing {@code DisputeSettlementDetail} object. */
public static DisputeSettlementDetail retrieve(
String disputeSettlementDetail,
DisputeSettlementDetailRetrieveParams params,
RequestOptions options)
throws StripeException {
String path =
String.format(
"/v1/issuing/dispute_settlement_details/%s",
ApiResource.urlEncodeId(disputeSettlementDetail));
ApiResource.checkNullTypedParams(path, params);
ApiRequest request =
new ApiRequest(
BaseAddress.API,
ApiResource.RequestMethod.GET,
path,
ApiRequestParams.paramsToMap(params),
options);
return getGlobalResponseGetter().request(request, DisputeSettlementDetail.class);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
// File generated from our OpenAPI spec
package com.stripe.model.issuing;

import com.stripe.model.StripeCollection;

public class DisputeSettlementDetailCollection extends StripeCollection<DisputeSettlementDetail> {}
107 changes: 107 additions & 0 deletions src/main/java/com/stripe/model/issuing/Settlement.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@
// File generated from our OpenAPI spec
package com.stripe.model.issuing;

import com.google.gson.annotations.SerializedName;
import com.stripe.model.HasId;
import com.stripe.model.StripeObject;
import java.util.Map;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.Setter;

/**
* When a non-stripe BIN is used, any use of an <a href="https://stripe.com/docs/issuing">issued
* card</a> must be settled directly with the card network. The net amount owed is represented by an
* Issuing {@code Settlement} object.
*/
@Getter
@Setter
@EqualsAndHashCode(callSuper = false)
public class Settlement extends StripeObject implements HasId {
/** The Bank Identification Number reflecting this settlement record. */
@SerializedName("bin")
String bin;

/** The date that the transactions are cleared and posted to user's accounts. */
@SerializedName("clearing_date")
Long clearingDate;

/** Time at which the object was created. Measured in seconds since the Unix epoch. */
@SerializedName("created")
Long created;

/**
* Three-letter <a href="https://www.iso.org/iso-4217-currency-codes.html">ISO currency code</a>,
* in lowercase. Must be a <a href="https://stripe.com/docs/currencies">supported currency</a>.
*/
@SerializedName("currency")
String currency;

/** Unique identifier for the object. */
@Getter(onMethod_ = {@Override})
@SerializedName("id")
String id;

/** The total interchange received as reimbursement for the transactions. */
@SerializedName("interchange_fees")
Long interchangeFees;

/**
* Has the value {@code true} if the object exists in live mode or the value {@code false} if the
* object exists in test mode.
*/
@SerializedName("livemode")
Boolean livemode;

/**
* Set of <a href="https://stripe.com/docs/api/metadata">key-value pairs</a> that you can attach
* to an object. This can be useful for storing additional information about the object in a
* structured format.
*/
@SerializedName("metadata")
Map<String, String> metadata;

/** The total net amount required to settle with the network. */
@SerializedName("net_total")
Long netTotal;

/** The card network for this settlement report. One of [&quot;visa&quot;, &quot;maestro&quot;] */
@SerializedName("network")
String network;

/** The total amount of fees owed to the network. */
@SerializedName("network_fees")
Long networkFees;

/** The Settlement Identification Number assigned by the network. */
@SerializedName("network_settlement_identifier")
String networkSettlementIdentifier;

/**
* String representing the object's type. Objects of the same type share the same value.
*
* <p>Equal to {@code issuing.settlement}.
*/
@SerializedName("object")
String object;

/** One of {@code international} or {@code uk_national_net}. */
@SerializedName("settlement_service")
String settlementService;

/**
* The current processing status of this settlement.
*
* <p>One of {@code complete}, or {@code pending}.
*/
@SerializedName("status")
String status;

/** The total number of transactions reflected in this settlement. */
@SerializedName("transaction_count")
Long transactionCount;

/** The total transaction amount reflected in this settlement. */
@SerializedName("transaction_volume")
Long transactionVolume;
}
Loading

0 comments on commit d3532c0

Please sign in to comment.