From 7018c3c6dc16e06b68b7c6e8cb4760ae3cb45b02 Mon Sep 17 00:00:00 2001 From: Alex Plumb Date: Mon, 28 May 2018 15:14:35 -0300 Subject: [PATCH 1/2] fix(add amount_returned to IOrder) --- types/stripe/index.d.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/types/stripe/index.d.ts b/types/stripe/index.d.ts index 991d4a618a..cf7a1e3c02 100644 --- a/types/stripe/index.d.ts +++ b/types/stripe/index.d.ts @@ -2306,6 +2306,12 @@ declare namespace Stripe { * currency) representing the total amount for the order. */ amount: number; + + /** + * A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a 0-decimal + * currency) representing the total amount returned for the order thus far. + */ + amount_returned: number; /** * ID of the Connect Application that created the order. From 0acfb18ec6005883836951e1b4d88a7b1edd6773 Mon Sep 17 00:00:00 2001 From: Alex Plumb Date: Tue, 29 May 2018 10:53:10 -0300 Subject: [PATCH 2/2] Add test for amount_returned --- types/stripe/stripe-tests.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/types/stripe/stripe-tests.ts b/types/stripe/stripe-tests.ts index 91cfa0f50c..306ab0442a 100644 --- a/types/stripe/stripe-tests.ts +++ b/types/stripe/stripe-tests.ts @@ -798,7 +798,10 @@ stripe.accounts.createExternalAccount("", { external_account: "tok_15V2YhEe31JkL //#region Orders tests // ################################################################################## - +stripe.orders.retrieve("or_1C8XKwEe31JkLCeQHg0jcisf", function (err, order) { + // asynchronously called + var amount_returned: number = order.amount_returned; +}); //#endregion