diff --git a/types/2019-12-03/Issuing/Disputes.d.ts b/types/2019-12-03/Issuing/Disputes.d.ts index f266b6b8dd..a8b8540f7e 100644 --- a/types/2019-12-03/Issuing/Disputes.d.ts +++ b/types/2019-12-03/Issuing/Disputes.d.ts @@ -48,7 +48,7 @@ declare module 'stripe' { metadata: Metadata; /** - * Reason for this dispute. One of `fraudulent` or `other`. + * Reason for this dispute. One of `duplicate`, `product_not_received`, `fraudulent`, or `other`. */ reason: string; @@ -60,6 +60,11 @@ declare module 'stripe' { namespace Dispute { interface Evidence { + /** + * Evidence to support a duplicate product dispute. This will only be present if your dispute's `reason` is `duplicate`. + */ + duplicate: Evidence.Duplicate | null; + /** * Evidence to support a fraudulent dispute. This will only be present if your dispute's `reason` is `fraudulent`. */ @@ -69,9 +74,31 @@ declare module 'stripe' { * Evidence to support an uncategorized dispute. This will only be present if your dispute's `reason` is `other`. */ other: Evidence.Other | null; + + /** + * Evidence to support a dispute where the product wasn't received. This will only be present if your dispute's `reason` is `product_not_received`. + */ + product_not_received: Evidence.ProductNotReceived | null; } namespace Evidence { + interface Duplicate { + /** + * Brief freeform text explaining why you are disputing this transaction. + */ + dispute_explanation: string | null; + + /** + * Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one. + */ + original_transaction: string | null; + + /** + * (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional file evidence supporting your dispute. + */ + uncategorized_file: string | Stripe.File | null; + } + interface Fraudulent { /** * Brief freeform text explaining why you are disputing this transaction. @@ -95,6 +122,18 @@ declare module 'stripe' { */ uncategorized_file: string | Stripe.File | null; } + + interface ProductNotReceived { + /** + * Brief freeform text explaining why you are disputing this transaction. + */ + dispute_explanation: string | null; + + /** + * (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional file evidence supporting your dispute. + */ + uncategorized_file: string | Stripe.File | null; + } } type Status = 'lost' | 'under_review' | 'unsubmitted' | 'won'; @@ -134,6 +173,11 @@ declare module 'stripe' { namespace DisputeCreateParams { interface Evidence { + /** + * Evidence to support a duplicate dispute. Only provide this if your dispute's `reason` is `duplicate`. + */ + duplicate?: Evidence.Duplicate; + /** * Evidence to support a fraudulent dispute. Only provide this if your dispute's `reason` is `fraudulent`. */ @@ -143,9 +187,31 @@ declare module 'stripe' { * Evidence to support an uncategorized dispute. Only provide this if your dispute's `reason` is `other`. */ other?: Evidence.Other; + + /** + * Evidence to support a dispute for a product that wasn't received. Only provide this if your dispute's `reason` is `product_not_received`. + */ + product_not_received?: Evidence.ProductNotReceived; } namespace Evidence { + interface Duplicate { + /** + * Brief freeform text explaining why you are disputing this transaction. + */ + dispute_explanation: string; + + /** + * Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one. + */ + original_transaction?: string; + + /** + * (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional file evidence supporting your dispute. + */ + uncategorized_file?: string; + } + interface Fraudulent { /** * Brief freeform text explaining why you are disputing this transaction. @@ -169,9 +235,25 @@ declare module 'stripe' { */ uncategorized_file?: string; } + + interface ProductNotReceived { + /** + * Brief freeform text explaining why you are disputing this transaction. + */ + dispute_explanation: string; + + /** + * (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional file evidence supporting your dispute. + */ + uncategorized_file?: string; + } } - type Reason = 'fraudulent' | 'other'; + type Reason = + | 'duplicate' + | 'fraudulent' + | 'other' + | 'product_not_received'; } interface DisputeRetrieveParams {