Skip to content

Commit

Permalink
Merge branch 'master' into richardm-usage
Browse files Browse the repository at this point in the history
  • Loading branch information
richardm-stripe committed Dec 14, 2023
2 parents 456f6e0 + a31d032 commit 7db57c5
Show file tree
Hide file tree
Showing 11 changed files with 147 additions and 9 deletions.
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v704
v715
3 changes: 0 additions & 3 deletions types/AccountSessionsResource.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,9 +127,6 @@ declare module 'stripe' {
*/
enabled: boolean;

/**
* The list of features enabled in the embedded component.
*/
features?: Payouts.Features;
}

Expand Down
30 changes: 30 additions & 0 deletions types/Checkout/Sessions.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -366,6 +366,11 @@ declare module 'stripe' {
}

interface ConsentCollection {
/**
* If set to `hidden`, it will hide legal text related to the reuse of a payment method.
*/
payment_method_reuse_agreement: ConsentCollection.PaymentMethodReuseAgreement | null;

/**
* If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
* Session will determine whether to display an option to opt into promotional communication
Expand All @@ -380,6 +385,19 @@ declare module 'stripe' {
}

namespace ConsentCollection {
interface PaymentMethodReuseAgreement {
/**
* Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's defaults will be used.
*
* When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
*/
position: PaymentMethodReuseAgreement.Position;
}

namespace PaymentMethodReuseAgreement {
type Position = 'auto' | 'hidden';
}

type Promotions = 'auto' | 'none';

type TermsOfService = 'none' | 'required';
Expand Down Expand Up @@ -631,6 +649,11 @@ declare module 'stripe' {
}

interface CustomText {
/**
* Custom text that should be displayed after the payment confirmation button.
*/
after_submit: CustomText.AfterSubmit | null;

/**
* Custom text that should be displayed alongside shipping address collection.
*/
Expand All @@ -648,6 +671,13 @@ declare module 'stripe' {
}

namespace CustomText {
interface AfterSubmit {
/**
* Text may be up to 1200 characters in length.
*/
message: string;
}

interface ShippingAddress {
/**
* Text may be up to 1200 characters in length.
Expand Down
29 changes: 29 additions & 0 deletions types/Checkout/SessionsResource.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -284,6 +284,11 @@ declare module 'stripe' {
type BillingAddressCollection = 'auto' | 'required';

interface ConsentCollection {
/**
* Determines the display of payment method reuse agreement text in the UI. If set to `hidden`, it will hide legal text related to the reuse of a payment method.
*/
payment_method_reuse_agreement?: ConsentCollection.PaymentMethodReuseAgreement;

/**
* If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
* Session will determine whether to display an option to opt into promotional communication
Expand All @@ -299,6 +304,18 @@ declare module 'stripe' {
}

namespace ConsentCollection {
interface PaymentMethodReuseAgreement {
/**
* Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's
* defaults will be used. When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
*/
position: PaymentMethodReuseAgreement.Position;
}

namespace PaymentMethodReuseAgreement {
type Position = 'auto' | 'hidden';
}

type Promotions = 'auto' | 'none';

type TermsOfService = 'none' | 'required';
Expand Down Expand Up @@ -432,6 +449,11 @@ declare module 'stripe' {
}

interface CustomText {
/**
* Custom text that should be displayed after the payment confirmation button.
*/
after_submit?: Stripe.Emptyable<CustomText.AfterSubmit>;

/**
* Custom text that should be displayed alongside shipping address collection.
*/
Expand All @@ -451,6 +473,13 @@ declare module 'stripe' {
}

namespace CustomText {
interface AfterSubmit {
/**
* Text may be up to 1200 characters in length.
*/
message: string;
}

interface ShippingAddress {
/**
* Text may be up to 1200 characters in length.
Expand Down
8 changes: 4 additions & 4 deletions types/InvoicesResource.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1410,7 +1410,7 @@ declare module 'stripe' {
| number;

/**
* Timestamp indicating when the subscription should be scheduled to cancel. Will prorate if within the current period and prorations have been enabled using `proration_behavior`.
* A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
*/
subscription_cancel_at?: Stripe.Emptyable<number>;

Expand Down Expand Up @@ -1452,7 +1452,7 @@ declare module 'stripe' {
subscription_resume_at?: 'now';

/**
* Date a subscription is intended to start (can be future or past)
* Date a subscription is intended to start (can be future or past).
*/
subscription_start_date?: number;

Expand Down Expand Up @@ -1995,7 +1995,7 @@ declare module 'stripe' {
| number;

/**
* Timestamp indicating when the subscription should be scheduled to cancel. Will prorate if within the current period and prorations have been enabled using `proration_behavior`.
* A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
*/
subscription_cancel_at?: Stripe.Emptyable<number>;

Expand Down Expand Up @@ -2037,7 +2037,7 @@ declare module 'stripe' {
subscription_resume_at?: 'now';

/**
* Date a subscription is intended to start (can be future or past)
* Date a subscription is intended to start (can be future or past).
*/
subscription_start_date?: number;

Expand Down
3 changes: 3 additions & 0 deletions types/PaymentIntents.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,9 @@ declare module 'stripe' {
*/
client_secret: string | null;

/**
* Describes whether we can confirm this PaymentIntent automatically, or if it requires customer action to confirm the payment.
*/
confirmation_method: PaymentIntent.ConfirmationMethod;

/**
Expand Down
3 changes: 3 additions & 0 deletions types/PaymentIntentsResource.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ declare module 'stripe' {
*/
confirm?: boolean;

/**
* Describes whether we can confirm this PaymentIntent automatically, or if it requires customer action to confirm the payment.
*/
confirmation_method?: PaymentIntentCreateParams.ConfirmationMethod;

/**
Expand Down
30 changes: 30 additions & 0 deletions types/PaymentLinks.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,11 @@ declare module 'stripe' {
type BillingAddressCollection = 'auto' | 'required';

interface ConsentCollection {
/**
* Settings related to the payment method reuse text shown in the Checkout UI.
*/
payment_method_reuse_agreement: ConsentCollection.PaymentMethodReuseAgreement | null;

/**
* If set to `auto`, enables the collection of customer consent for promotional communications.
*/
Expand All @@ -217,6 +222,19 @@ declare module 'stripe' {
}

namespace ConsentCollection {
interface PaymentMethodReuseAgreement {
/**
* Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's defaults will be used.
*
* When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
*/
position: PaymentMethodReuseAgreement.Position;
}

namespace PaymentMethodReuseAgreement {
type Position = 'auto' | 'hidden';
}

type Promotions = 'auto' | 'none';

type TermsOfService = 'none' | 'required';
Expand Down Expand Up @@ -311,6 +329,11 @@ declare module 'stripe' {
}

interface CustomText {
/**
* Custom text that should be displayed after the payment confirmation button.
*/
after_submit: CustomText.AfterSubmit | null;

/**
* Custom text that should be displayed alongside shipping address collection.
*/
Expand All @@ -328,6 +351,13 @@ declare module 'stripe' {
}

namespace CustomText {
interface AfterSubmit {
/**
* Text may be up to 1200 characters in length.
*/
message: string;
}

interface ShippingAddress {
/**
* Text may be up to 1200 characters in length.
Expand Down
41 changes: 41 additions & 0 deletions types/PaymentLinksResource.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,11 @@ declare module 'stripe' {
type BillingAddressCollection = 'auto' | 'required';

interface ConsentCollection {
/**
* Determines the display of payment method reuse agreement text in the UI. If set to `hidden`, it will hide legal text related to the reuse of a payment method.
*/
payment_method_reuse_agreement?: ConsentCollection.PaymentMethodReuseAgreement;

/**
* If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
* Session will determine whether to display an option to opt into promotional communication
Expand All @@ -211,6 +216,18 @@ declare module 'stripe' {
}

namespace ConsentCollection {
interface PaymentMethodReuseAgreement {
/**
* Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's
* defaults will be used. When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
*/
position: PaymentMethodReuseAgreement.Position;
}

namespace PaymentMethodReuseAgreement {
type Position = 'auto' | 'hidden';
}

type Promotions = 'auto' | 'none';

type TermsOfService = 'none' | 'required';
Expand Down Expand Up @@ -317,6 +334,11 @@ declare module 'stripe' {
}

interface CustomText {
/**
* Custom text that should be displayed after the payment confirmation button.
*/
after_submit?: Stripe.Emptyable<CustomText.AfterSubmit>;

/**
* Custom text that should be displayed alongside shipping address collection.
*/
Expand All @@ -336,6 +358,13 @@ declare module 'stripe' {
}

namespace CustomText {
interface AfterSubmit {
/**
* Text may be up to 1200 characters in length.
*/
message: string;
}

interface ShippingAddress {
/**
* Text may be up to 1200 characters in length.
Expand Down Expand Up @@ -1160,6 +1189,11 @@ declare module 'stripe' {
}

interface CustomText {
/**
* Custom text that should be displayed after the payment confirmation button.
*/
after_submit?: Stripe.Emptyable<CustomText.AfterSubmit>;

/**
* Custom text that should be displayed alongside shipping address collection.
*/
Expand All @@ -1179,6 +1213,13 @@ declare module 'stripe' {
}

namespace CustomText {
interface AfterSubmit {
/**
* Text may be up to 1200 characters in length.
*/
message: string;
}

interface ShippingAddress {
/**
* Text may be up to 1200 characters in length.
Expand Down
5 changes: 5 additions & 0 deletions types/Radar/EarlyFraudWarningsResource.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ declare module 'stripe' {
*/
charge?: string;

/**
* Only return early fraud warnings that were created during the given date interval.
*/
created?: Stripe.RangeQueryParam | number;

/**
* Specifies which fields in the response should be expanded.
*/
Expand Down
2 changes: 1 addition & 1 deletion types/TestHelpers/Issuing/AuthorizationsResource.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ declare module 'stripe' {
namespace Issuing {
interface AuthorizationCreateParams {
/**
* The total amount to attempt to authorize. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
* The total amount to attempt to authorize. This amount is in the provided currency, or defaults to the card's currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
*/
amount: number;

Expand Down

0 comments on commit 7db57c5

Please sign in to comment.