Skip to content

Commit

Permalink
Update generated code for v552
Browse files Browse the repository at this point in the history
  • Loading branch information
stripe-openapi[bot] committed Sep 25, 2023
1 parent f15285b commit 79c7b3e
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 5 deletions.
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v551
v552
32 changes: 28 additions & 4 deletions types/RefundsResource.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@
declare module 'stripe' {
namespace Stripe {
interface RefundCreateParams {
/**
* A positive integer representing how much to refund.
*/
amount?: number;

/**
* The identifier of the charge to refund.
*/
charge?: string;

/**
Expand Down Expand Up @@ -40,12 +40,26 @@ declare module 'stripe' {
*/
origin?: 'customer_balance';

/**
* The identifier of the PaymentIntent to refund.
*/
payment_intent?: string;

/**
* String indicating the reason for the refund. If set, possible values are `duplicate`, `fraudulent`, and `requested_by_customer`. If you believe the charge to be fraudulent, specifying `fraudulent` as the reason will add the associated card and email to your [block lists](https://stripe.com/docs/radar/lists), and will also help us improve our fraud detection algorithms.
*/
reason?: RefundCreateParams.Reason;

/**
* Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.
*/
refund_application_fee?: boolean;

/**
* Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount).
*
* A transfer can be reversed only by the application that created the charge.
*/
reverse_transfer?: boolean;
}

Expand Down Expand Up @@ -100,7 +114,17 @@ declare module 'stripe' {

class RefundsResource {
/**
* Create a refund.
* When you create a new refund, you must specify a Charge or a PaymentIntent object on which to create it.
*
* Creating a new refund will refund a charge that has previously been created but not yet refunded.
* Funds will be refunded to the credit or debit card that was originally charged.
*
* You can optionally refund only part of a charge.
* You can do so multiple times, until the entire charge has been refunded.
*
* Once entirely refunded, a charge can't be refunded again.
* This method will raise an error when called on an already-refunded charge,
* or when trying to refund more money than is left on a charge.
*/
create(
params?: RefundCreateParams,
Expand Down

0 comments on commit 79c7b3e

Please sign in to comment.