From a9c5fe016a24cd468076917cab7ec7aa6583c4bc Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Fri, 10 Jan 2025 03:16:47 +0000 Subject: [PATCH 01/17] Update generated code for v1439 --- OPENAPI_VERSION | 2 +- .../Configurations/ConfigurationTipping.cs | 6 +++ .../Configurations/ConfigurationTippingJpy.cs | 40 +++++++++++++++++++ .../ConfigurationTippingJpyOptions.cs | 40 +++++++++++++++++++ .../ConfigurationTippingOptions.cs | 9 +++++ 5 files changed, 96 insertions(+), 1 deletion(-) create mode 100644 src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTippingJpy.cs create mode 100644 src/Stripe.net/Services/Terminal/Configurations/ConfigurationTippingJpyOptions.cs diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 26f0624c9..1de7c5643 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1438 \ No newline at end of file +v1439 \ No newline at end of file diff --git a/src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTipping.cs b/src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTipping.cs index 39743289f..48de1d68a 100644 --- a/src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTipping.cs +++ b/src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTipping.cs @@ -56,6 +56,12 @@ public class ConfigurationTipping : StripeEntity #endif public ConfigurationTippingHkd Hkd { get; set; } + [JsonProperty("jpy")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("jpy")] +#endif + public ConfigurationTippingJpy Jpy { get; set; } + [JsonProperty("myr")] #if NET6_0_OR_GREATER [STJS.JsonPropertyName("myr")] diff --git a/src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTippingJpy.cs b/src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTippingJpy.cs new file mode 100644 index 000000000..a54c5c152 --- /dev/null +++ b/src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTippingJpy.cs @@ -0,0 +1,40 @@ +// File generated from our OpenAPI spec +namespace Stripe.Terminal +{ + using System.Collections.Generic; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class ConfigurationTippingJpy : StripeEntity + { + /// + /// Fixed amounts displayed when collecting a tip. + /// + [JsonProperty("fixed_amounts")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("fixed_amounts")] +#endif + public List FixedAmounts { get; set; } + + /// + /// Percentages displayed when collecting a tip. + /// + [JsonProperty("percentages")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("percentages")] +#endif + public List Percentages { get; set; } + + /// + /// Below this amount, fixed amounts will be displayed; above it, percentages will be + /// displayed. + /// + [JsonProperty("smart_tip_threshold")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("smart_tip_threshold")] +#endif + public long SmartTipThreshold { get; set; } + } +} diff --git a/src/Stripe.net/Services/Terminal/Configurations/ConfigurationTippingJpyOptions.cs b/src/Stripe.net/Services/Terminal/Configurations/ConfigurationTippingJpyOptions.cs new file mode 100644 index 000000000..137397fd7 --- /dev/null +++ b/src/Stripe.net/Services/Terminal/Configurations/ConfigurationTippingJpyOptions.cs @@ -0,0 +1,40 @@ +// File generated from our OpenAPI spec +namespace Stripe.Terminal +{ + using System.Collections.Generic; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class ConfigurationTippingJpyOptions : INestedOptions + { + /// + /// Fixed amounts displayed when collecting a tip. + /// + [JsonProperty("fixed_amounts")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("fixed_amounts")] +#endif + public List FixedAmounts { get; set; } + + /// + /// Percentages displayed when collecting a tip. + /// + [JsonProperty("percentages")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("percentages")] +#endif + public List Percentages { get; set; } + + /// + /// Below this amount, fixed amounts will be displayed; above it, percentages will be + /// displayed. + /// + [JsonProperty("smart_tip_threshold")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("smart_tip_threshold")] +#endif + public long? SmartTipThreshold { get; set; } + } +} diff --git a/src/Stripe.net/Services/Terminal/Configurations/ConfigurationTippingOptions.cs b/src/Stripe.net/Services/Terminal/Configurations/ConfigurationTippingOptions.cs index 1c9185661..99cb9ca5c 100644 --- a/src/Stripe.net/Services/Terminal/Configurations/ConfigurationTippingOptions.cs +++ b/src/Stripe.net/Services/Terminal/Configurations/ConfigurationTippingOptions.cs @@ -80,6 +80,15 @@ public class ConfigurationTippingOptions : INestedOptions #endif public ConfigurationTippingHkdOptions Hkd { get; set; } + /// + /// Tipping configuration for JPY. + /// + [JsonProperty("jpy")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("jpy")] +#endif + public ConfigurationTippingJpyOptions Jpy { get; set; } + /// /// Tipping configuration for MYR. /// From 0b26eb0cb02d84df38ac6cebdf7c254e37c757a6 Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Fri, 10 Jan 2025 22:02:19 +0000 Subject: [PATCH 02/17] Update generated code for v1441 --- OPENAPI_VERSION | 2 +- .../AccountSessionComponents.cs | 24 ++++++++ ...ccountSessionComponentsFinancialAccount.cs | 26 +++++++++ ...ssionComponentsFinancialAccountFeatures.cs | 51 ++++++++++++++++ ...nComponentsFinancialAccountTransactions.cs | 26 +++++++++ ...ntsFinancialAccountTransactionsFeatures.cs | 20 +++++++ .../AccountSessionComponentsIssuingCard.cs | 26 +++++++++ ...untSessionComponentsIssuingCardFeatures.cs | 47 +++++++++++++++ ...ccountSessionComponentsIssuingCardsList.cs | 26 +++++++++ ...ssionComponentsIssuingCardsListFeatures.cs | 58 +++++++++++++++++++ .../AccountSessionComponentsOptions.cs | 8 +-- 11 files changed, 309 insertions(+), 5 deletions(-) create mode 100644 src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccount.cs create mode 100644 src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccountFeatures.cs create mode 100644 src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccountTransactions.cs create mode 100644 src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccountTransactionsFeatures.cs create mode 100644 src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCard.cs create mode 100644 src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCardFeatures.cs create mode 100644 src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCardsList.cs create mode 100644 src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCardsListFeatures.cs diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 1de7c5643..9aa5de967 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1439 \ No newline at end of file +v1441 \ No newline at end of file diff --git a/src/Stripe.net/Entities/AccountSessions/AccountSessionComponents.cs b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponents.cs index 973d57024..6d6829142 100644 --- a/src/Stripe.net/Entities/AccountSessions/AccountSessionComponents.cs +++ b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponents.cs @@ -50,6 +50,30 @@ public class AccountSessionComponents : StripeEntity #endif public AccountSessionComponentsDocuments Documents { get; set; } + [JsonProperty("financial_account")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("financial_account")] +#endif + public AccountSessionComponentsFinancialAccount FinancialAccount { get; set; } + + [JsonProperty("financial_account_transactions")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("financial_account_transactions")] +#endif + public AccountSessionComponentsFinancialAccountTransactions FinancialAccountTransactions { get; set; } + + [JsonProperty("issuing_card")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("issuing_card")] +#endif + public AccountSessionComponentsIssuingCard IssuingCard { get; set; } + + [JsonProperty("issuing_cards_list")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("issuing_cards_list")] +#endif + public AccountSessionComponentsIssuingCardsList IssuingCardsList { get; set; } + [JsonProperty("notification_banner")] #if NET6_0_OR_GREATER [STJS.JsonPropertyName("notification_banner")] diff --git a/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccount.cs b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccount.cs new file mode 100644 index 000000000..25ec7924f --- /dev/null +++ b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccount.cs @@ -0,0 +1,26 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountSessionComponentsFinancialAccount : StripeEntity + { + /// + /// Whether the embedded component is enabled. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool Enabled { get; set; } + + [JsonProperty("features")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("features")] +#endif + public AccountSessionComponentsFinancialAccountFeatures Features { get; set; } + } +} diff --git a/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccountFeatures.cs b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccountFeatures.cs new file mode 100644 index 000000000..c87f6b64f --- /dev/null +++ b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccountFeatures.cs @@ -0,0 +1,51 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountSessionComponentsFinancialAccountFeatures : StripeEntity + { + /// + /// Disables Stripe user authentication for this embedded component. This value can only be + /// true for accounts where controller.requirement_collection is application. + /// The default value is the opposite of the external_account_collection value. For + /// example, if you don’t set external_account_collection, it defaults to true and + /// disable_stripe_user_authentication defaults to false. + /// + [JsonProperty("disable_stripe_user_authentication")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("disable_stripe_user_authentication")] +#endif + public bool DisableStripeUserAuthentication { get; set; } + + /// + /// Whether to allow external accounts to be linked for money transfer. + /// + [JsonProperty("external_account_collection")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("external_account_collection")] +#endif + public bool ExternalAccountCollection { get; set; } + + /// + /// Whether to allow sending money. + /// + [JsonProperty("send_money")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("send_money")] +#endif + public bool SendMoney { get; set; } + + /// + /// Whether to allow transferring balance. + /// + [JsonProperty("transfer_balance")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("transfer_balance")] +#endif + public bool TransferBalance { get; set; } + } +} diff --git a/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccountTransactions.cs b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccountTransactions.cs new file mode 100644 index 000000000..f042ed75c --- /dev/null +++ b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccountTransactions.cs @@ -0,0 +1,26 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountSessionComponentsFinancialAccountTransactions : StripeEntity + { + /// + /// Whether the embedded component is enabled. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool Enabled { get; set; } + + [JsonProperty("features")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("features")] +#endif + public AccountSessionComponentsFinancialAccountTransactionsFeatures Features { get; set; } + } +} diff --git a/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccountTransactionsFeatures.cs b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccountTransactionsFeatures.cs new file mode 100644 index 000000000..21367eb0a --- /dev/null +++ b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsFinancialAccountTransactionsFeatures.cs @@ -0,0 +1,20 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountSessionComponentsFinancialAccountTransactionsFeatures : StripeEntity + { + /// + /// Whether to allow card spend dispute management features. + /// + [JsonProperty("card_spend_dispute_management")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("card_spend_dispute_management")] +#endif + public bool CardSpendDisputeManagement { get; set; } + } +} diff --git a/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCard.cs b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCard.cs new file mode 100644 index 000000000..7ca02510f --- /dev/null +++ b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCard.cs @@ -0,0 +1,26 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountSessionComponentsIssuingCard : StripeEntity + { + /// + /// Whether the embedded component is enabled. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool Enabled { get; set; } + + [JsonProperty("features")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("features")] +#endif + public AccountSessionComponentsIssuingCardFeatures Features { get; set; } + } +} diff --git a/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCardFeatures.cs b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCardFeatures.cs new file mode 100644 index 000000000..5a9844493 --- /dev/null +++ b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCardFeatures.cs @@ -0,0 +1,47 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountSessionComponentsIssuingCardFeatures : StripeEntity + { + /// + /// Whether to allow card management features. + /// + [JsonProperty("card_management")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("card_management")] +#endif + public bool CardManagement { get; set; } + + /// + /// Whether to allow card spend dispute management features. + /// + [JsonProperty("card_spend_dispute_management")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("card_spend_dispute_management")] +#endif + public bool CardSpendDisputeManagement { get; set; } + + /// + /// Whether to allow cardholder management features. + /// + [JsonProperty("cardholder_management")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("cardholder_management")] +#endif + public bool CardholderManagement { get; set; } + + /// + /// Whether to allow spend control management features. + /// + [JsonProperty("spend_control_management")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("spend_control_management")] +#endif + public bool SpendControlManagement { get; set; } + } +} diff --git a/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCardsList.cs b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCardsList.cs new file mode 100644 index 000000000..6eed2b5b9 --- /dev/null +++ b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCardsList.cs @@ -0,0 +1,26 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountSessionComponentsIssuingCardsList : StripeEntity + { + /// + /// Whether the embedded component is enabled. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool Enabled { get; set; } + + [JsonProperty("features")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("features")] +#endif + public AccountSessionComponentsIssuingCardsListFeatures Features { get; set; } + } +} diff --git a/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCardsListFeatures.cs b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCardsListFeatures.cs new file mode 100644 index 000000000..450117a72 --- /dev/null +++ b/src/Stripe.net/Entities/AccountSessions/AccountSessionComponentsIssuingCardsListFeatures.cs @@ -0,0 +1,58 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountSessionComponentsIssuingCardsListFeatures : StripeEntity + { + /// + /// Whether to allow card management features. + /// + [JsonProperty("card_management")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("card_management")] +#endif + public bool CardManagement { get; set; } + + /// + /// Whether to allow card spend dispute management features. + /// + [JsonProperty("card_spend_dispute_management")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("card_spend_dispute_management")] +#endif + public bool CardSpendDisputeManagement { get; set; } + + /// + /// Whether to allow cardholder management features. + /// + [JsonProperty("cardholder_management")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("cardholder_management")] +#endif + public bool CardholderManagement { get; set; } + + /// + /// Disables Stripe user authentication for this embedded component. This feature can only + /// be false for accounts where you’re responsible for collecting updated information when + /// requirements are due or change, like custom accounts. + /// + [JsonProperty("disable_stripe_user_authentication")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("disable_stripe_user_authentication")] +#endif + public bool DisableStripeUserAuthentication { get; set; } + + /// + /// Whether to allow spend control management features. + /// + [JsonProperty("spend_control_management")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("spend_control_management")] +#endif + public bool SpendControlManagement { get; set; } + } +} diff --git a/src/Stripe.net/Services/AccountSessions/AccountSessionComponentsOptions.cs b/src/Stripe.net/Services/AccountSessions/AccountSessionComponentsOptions.cs index ec5c2bb7b..10282de28 100644 --- a/src/Stripe.net/Services/AccountSessions/AccountSessionComponentsOptions.cs +++ b/src/Stripe.net/Services/AccountSessions/AccountSessionComponentsOptions.cs @@ -99,7 +99,7 @@ public class AccountSessionComponentsOptions : INestedOptions public AccountSessionComponentsDocumentsOptions Documents { get; set; } /// - /// Configuration for the financial account component. + /// Configuration for the financial account embedded component. /// [JsonProperty("financial_account")] #if NET6_0_OR_GREATER @@ -108,7 +108,7 @@ public class AccountSessionComponentsOptions : INestedOptions public AccountSessionComponentsFinancialAccountOptions FinancialAccount { get; set; } /// - /// Configuration for the financial account transactions component. + /// Configuration for the financial account transactions embedded component. /// [JsonProperty("financial_account_transactions")] #if NET6_0_OR_GREATER @@ -117,7 +117,7 @@ public class AccountSessionComponentsOptions : INestedOptions public AccountSessionComponentsFinancialAccountTransactionsOptions FinancialAccountTransactions { get; set; } /// - /// Configuration for the issuing card component. + /// Configuration for the issuing card embedded component. /// [JsonProperty("issuing_card")] #if NET6_0_OR_GREATER @@ -126,7 +126,7 @@ public class AccountSessionComponentsOptions : INestedOptions public AccountSessionComponentsIssuingCardOptions IssuingCard { get; set; } /// - /// Configuration for the issuing cards list component. + /// Configuration for the issuing cards list embedded component. /// [JsonProperty("issuing_cards_list")] #if NET6_0_OR_GREATER From a113a4e448c979889ea95f14aa8c9a909abb0b61 Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Mon, 13 Jan 2025 22:17:24 +0000 Subject: [PATCH 03/17] Update generated code for v1441 --- src/StripeTests/Services/GeneratedExamplesTest.cs | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/StripeTests/Services/GeneratedExamplesTest.cs b/src/StripeTests/Services/GeneratedExamplesTest.cs index f2de39d17..3410f25ec 100644 --- a/src/StripeTests/Services/GeneratedExamplesTest.cs +++ b/src/StripeTests/Services/GeneratedExamplesTest.cs @@ -4531,6 +4531,21 @@ public void TestTerminalReadersProcessPaymentIntentPost() "/v1/terminal/readers/tmr_xxxxxxxxxxxxx/process_payment_intent"); } + [Fact] + public void TestTerminalReadersProcessSetupIntentPost() + { + var options = new Stripe.Terminal.ReaderProcessSetupIntentOptions + { + SetupIntent = "seti_xxxxxxxxxxxxx", + AllowRedisplay = "always", + }; + var service = new Stripe.Terminal.ReaderService(this.StripeClient); + service.ProcessSetupIntent("tmr_xxxxxxxxxxxxx", options); + this.AssertRequest( + HttpMethod.Post, + "/v1/terminal/readers/tmr_xxxxxxxxxxxxx/process_setup_intent"); + } + [Fact] public void TestTestHelpersCustomersFundCashBalancePost() { From 9fc5b2daa5e37359f7e9db0d60576be4c19baa1a Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Tue, 14 Jan 2025 08:46:01 +0000 Subject: [PATCH 04/17] Update generated code for v1442 --- OPENAPI_VERSION | 2 +- .../AccountSessionComponentsOptions.cs | 9 ++++++ ...tsTaxThresholdMonitoringFeaturesOptions.cs | 7 +++++ ...ComponentsTaxThresholdMonitoringOptions.cs | 29 +++++++++++++++++++ 4 files changed, 46 insertions(+), 1 deletion(-) create mode 100644 src/Stripe.net/Services/AccountSessions/AccountSessionComponentsTaxThresholdMonitoringFeaturesOptions.cs create mode 100644 src/Stripe.net/Services/AccountSessions/AccountSessionComponentsTaxThresholdMonitoringOptions.cs diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 9aa5de967..d618ca7df 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1441 \ No newline at end of file +v1442 \ No newline at end of file diff --git a/src/Stripe.net/Services/AccountSessions/AccountSessionComponentsOptions.cs b/src/Stripe.net/Services/AccountSessions/AccountSessionComponentsOptions.cs index 10282de28..295488b99 100644 --- a/src/Stripe.net/Services/AccountSessions/AccountSessionComponentsOptions.cs +++ b/src/Stripe.net/Services/AccountSessions/AccountSessionComponentsOptions.cs @@ -223,5 +223,14 @@ public class AccountSessionComponentsOptions : INestedOptions [STJS.JsonPropertyName("tax_settings")] #endif public AccountSessionComponentsTaxSettingsOptions TaxSettings { get; set; } + + /// + /// Configuration for the tax threshold monitoring embedded component. + /// + [JsonProperty("tax_threshold_monitoring")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("tax_threshold_monitoring")] +#endif + public AccountSessionComponentsTaxThresholdMonitoringOptions TaxThresholdMonitoring { get; set; } } } diff --git a/src/Stripe.net/Services/AccountSessions/AccountSessionComponentsTaxThresholdMonitoringFeaturesOptions.cs b/src/Stripe.net/Services/AccountSessions/AccountSessionComponentsTaxThresholdMonitoringFeaturesOptions.cs new file mode 100644 index 000000000..7ce007ea3 --- /dev/null +++ b/src/Stripe.net/Services/AccountSessions/AccountSessionComponentsTaxThresholdMonitoringFeaturesOptions.cs @@ -0,0 +1,7 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + public class AccountSessionComponentsTaxThresholdMonitoringFeaturesOptions : INestedOptions + { + } +} diff --git a/src/Stripe.net/Services/AccountSessions/AccountSessionComponentsTaxThresholdMonitoringOptions.cs b/src/Stripe.net/Services/AccountSessions/AccountSessionComponentsTaxThresholdMonitoringOptions.cs new file mode 100644 index 000000000..cc6ce43c4 --- /dev/null +++ b/src/Stripe.net/Services/AccountSessions/AccountSessionComponentsTaxThresholdMonitoringOptions.cs @@ -0,0 +1,29 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountSessionComponentsTaxThresholdMonitoringOptions : INestedOptions + { + /// + /// Whether the embedded component is enabled. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool? Enabled { get; set; } + + /// + /// The list of features enabled in the embedded component. + /// + [JsonProperty("features")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("features")] +#endif + public AccountSessionComponentsTaxThresholdMonitoringFeaturesOptions Features { get; set; } + } +} From 5cff5c7ab2ad06d82b83dabc04477633f5b608ff Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Tue, 14 Jan 2025 10:55:03 +0000 Subject: [PATCH 05/17] Update generated code for v1443 --- OPENAPI_VERSION | 2 +- .../Entities/Accounts/AccountCapabilities.cs | 11 ++++++++++ .../Accounts/AccountCapabilitiesOptions.cs | 9 ++++++++ ...untCapabilitiesPayByBankPaymentsOptions.cs | 22 +++++++++++++++++++ 4 files changed, 43 insertions(+), 1 deletion(-) create mode 100644 src/Stripe.net/Services/Accounts/AccountCapabilitiesPayByBankPaymentsOptions.cs diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index d618ca7df..023992bf5 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1442 \ No newline at end of file +v1443 \ No newline at end of file diff --git a/src/Stripe.net/Entities/Accounts/AccountCapabilities.cs b/src/Stripe.net/Entities/Accounts/AccountCapabilities.cs index 2e3bf450f..5a027ad33 100644 --- a/src/Stripe.net/Entities/Accounts/AccountCapabilities.cs +++ b/src/Stripe.net/Entities/Accounts/AccountCapabilities.cs @@ -456,6 +456,17 @@ public class AccountCapabilities : StripeEntity #endif public string P24Payments { get; set; } + /// + /// The status of the pay_by_bank payments capability of the account, or whether the account + /// can directly process pay_by_bank charges. + /// One of: active, inactive, or pending. + /// + [JsonProperty("pay_by_bank_payments")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("pay_by_bank_payments")] +#endif + public string PayByBankPayments { get; set; } + /// /// The status of the Payco capability of the account, or whether the account can directly /// process Payco payments. diff --git a/src/Stripe.net/Services/Accounts/AccountCapabilitiesOptions.cs b/src/Stripe.net/Services/Accounts/AccountCapabilitiesOptions.cs index 32b3c4962..b60eeee23 100644 --- a/src/Stripe.net/Services/Accounts/AccountCapabilitiesOptions.cs +++ b/src/Stripe.net/Services/Accounts/AccountCapabilitiesOptions.cs @@ -377,6 +377,15 @@ public class AccountCapabilitiesOptions : INestedOptions #endif public AccountCapabilitiesP24PaymentsOptions P24Payments { get; set; } + /// + /// The pay_by_bank_payments capability. + /// + [JsonProperty("pay_by_bank_payments")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("pay_by_bank_payments")] +#endif + public AccountCapabilitiesPayByBankPaymentsOptions PayByBankPayments { get; set; } + /// /// The payco_payments capability. /// diff --git a/src/Stripe.net/Services/Accounts/AccountCapabilitiesPayByBankPaymentsOptions.cs b/src/Stripe.net/Services/Accounts/AccountCapabilitiesPayByBankPaymentsOptions.cs new file mode 100644 index 000000000..3a431c26c --- /dev/null +++ b/src/Stripe.net/Services/Accounts/AccountCapabilitiesPayByBankPaymentsOptions.cs @@ -0,0 +1,22 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountCapabilitiesPayByBankPaymentsOptions : INestedOptions + { + /// + /// Passing true requests the capability for the account, if it is not already requested. A + /// requested capability may not immediately become active. Any requirements to activate the + /// capability are returned in the requirements arrays. + /// + [JsonProperty("requested")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("requested")] +#endif + public bool? Requested { get; set; } + } +} From f512bbbc981eedbfabccab71329038c38f4de172 Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Tue, 14 Jan 2025 16:11:52 +0000 Subject: [PATCH 06/17] Update generated code for v1444 --- OPENAPI_VERSION | 2 +- .../Sessions/SessionShippingAddressCollection.cs | 16 ++++++++-------- .../PaymentLinkShippingAddressCollection.cs | 14 +++++++------- .../SessionShippingAddressCollectionOptions.cs | 14 +++++++------- ...aymentLinkShippingAddressCollectionOptions.cs | 14 +++++++------- 5 files changed, 30 insertions(+), 30 deletions(-) diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 023992bf5..53bf35301 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1443 \ No newline at end of file +v1444 \ No newline at end of file diff --git a/src/Stripe.net/Entities/Checkout/Sessions/SessionShippingAddressCollection.cs b/src/Stripe.net/Entities/Checkout/Sessions/SessionShippingAddressCollection.cs index 9be5c7dab..b410d9972 100644 --- a/src/Stripe.net/Entities/Checkout/Sessions/SessionShippingAddressCollection.cs +++ b/src/Stripe.net/Entities/Checkout/Sessions/SessionShippingAddressCollection.cs @@ -12,7 +12,7 @@ public class SessionShippingAddressCollection : StripeEntity /// An array of two-letter ISO country codes representing which countries Checkout should /// provide as options for shipping locations. Unsupported country codes: AS, CX, CC, CU, - /// HM, IR, KP, MH, FM, NF, MP, PW, SD, SY, UM, VI. + /// HM, IR, KP, MH, FM, NF, MP, PW, SY, UM, VI. /// One of: AC, AD, AE, AF, AG, AI, AL, /// AM, AO, AQ, AR, AT, AU, AW, AX, /// AZ, BA, BB, BD, BE, BF, BG, BH, @@ -36,13 +36,13 @@ public class SessionShippingAddressCollection : StripeEntityNU, NZ, OM, PA, PE, PF, PG, PH, /// PK, PL, PM, PN, PR, PS, PT, PY, /// QA, RE, RO, RS, RU, RW, SA, SB, - /// SC, SE, SG, SH, SI, SJ, SK, SL, - /// SM, SN, SO, SR, SS, ST, SV, SX, - /// SZ, TA, TC, TD, TF, TG, TH, TJ, - /// TK, TL, TM, TN, TO, TR, TT, TV, - /// TW, TZ, UA, UG, US, UY, UZ, VA, - /// VC, VE, VG, VN, VU, WF, WS, XK, - /// YE, YT, ZA, ZM, ZW, or ZZ. + /// SC, SD, SE, SG, SH, SI, SJ, SK, + /// SL, SM, SN, SO, SR, SS, ST, SV, + /// SX, SZ, TA, TC, TD, TF, TG, TH, + /// TJ, TK, TL, TM, TN, TO, TR, TT, + /// TV, TW, TZ, UA, UG, US, UY, UZ, + /// VA, VC, VE, VG, VN, VU, WF, WS, + /// XK, YE, YT, ZA, ZM, ZW, or ZZ. /// [JsonProperty("allowed_countries")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/PaymentLinks/PaymentLinkShippingAddressCollection.cs b/src/Stripe.net/Entities/PaymentLinks/PaymentLinkShippingAddressCollection.cs index 7afaea6f6..8192032f9 100644 --- a/src/Stripe.net/Entities/PaymentLinks/PaymentLinkShippingAddressCollection.cs +++ b/src/Stripe.net/Entities/PaymentLinks/PaymentLinkShippingAddressCollection.cs @@ -36,13 +36,13 @@ public class PaymentLinkShippingAddressCollection : StripeEntityNU, NZ, OM, PA, PE, PF, PG, PH, /// PK, PL, PM, PN, PR, PS, PT, PY, /// QA, RE, RO, RS, RU, RW, SA, SB, - /// SC, SE, SG, SH, SI, SJ, SK, SL, - /// SM, SN, SO, SR, SS, ST, SV, SX, - /// SZ, TA, TC, TD, TF, TG, TH, TJ, - /// TK, TL, TM, TN, TO, TR, TT, TV, - /// TW, TZ, UA, UG, US, UY, UZ, VA, - /// VC, VE, VG, VN, VU, WF, WS, XK, - /// YE, YT, ZA, ZM, ZW, or ZZ. + /// SC, SD, SE, SG, SH, SI, SJ, SK, + /// SL, SM, SN, SO, SR, SS, ST, SV, + /// SX, SZ, TA, TC, TD, TF, TG, TH, + /// TJ, TK, TL, TM, TN, TO, TR, TT, + /// TV, TW, TZ, UA, UG, US, UY, UZ, + /// VA, VC, VE, VG, VN, VU, WF, WS, + /// XK, YE, YT, ZA, ZM, ZW, or ZZ. /// [JsonProperty("allowed_countries")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/Checkout/Sessions/SessionShippingAddressCollectionOptions.cs b/src/Stripe.net/Services/Checkout/Sessions/SessionShippingAddressCollectionOptions.cs index 0922df50c..b0fa31c69 100644 --- a/src/Stripe.net/Services/Checkout/Sessions/SessionShippingAddressCollectionOptions.cs +++ b/src/Stripe.net/Services/Checkout/Sessions/SessionShippingAddressCollectionOptions.cs @@ -35,13 +35,13 @@ public class SessionShippingAddressCollectionOptions : INestedOptions /// NU, NZ, OM, PA, PE, PF, PG, PH, /// PK, PL, PM, PN, PR, PS, PT, PY, /// QA, RE, RO, RS, RU, RW, SA, SB, - /// SC, SE, SG, SH, SI, SJ, SK, SL, - /// SM, SN, SO, SR, SS, ST, SV, SX, - /// SZ, TA, TC, TD, TF, TG, TH, TJ, - /// TK, TL, TM, TN, TO, TR, TT, TV, - /// TW, TZ, UA, UG, US, UY, UZ, VA, - /// VC, VE, VG, VN, VU, WF, WS, XK, - /// YE, YT, ZA, ZM, ZW, or ZZ. + /// SC, SD, SE, SG, SH, SI, SJ, SK, + /// SL, SM, SN, SO, SR, SS, ST, SV, + /// SX, SZ, TA, TC, TD, TF, TG, TH, + /// TJ, TK, TL, TM, TN, TO, TR, TT, + /// TV, TW, TZ, UA, UG, US, UY, UZ, + /// VA, VC, VE, VG, VN, VU, WF, WS, + /// XK, YE, YT, ZA, ZM, ZW, or ZZ. /// [JsonProperty("allowed_countries")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/PaymentLinks/PaymentLinkShippingAddressCollectionOptions.cs b/src/Stripe.net/Services/PaymentLinks/PaymentLinkShippingAddressCollectionOptions.cs index b4fc4a1f9..9e918825f 100644 --- a/src/Stripe.net/Services/PaymentLinks/PaymentLinkShippingAddressCollectionOptions.cs +++ b/src/Stripe.net/Services/PaymentLinks/PaymentLinkShippingAddressCollectionOptions.cs @@ -35,13 +35,13 @@ public class PaymentLinkShippingAddressCollectionOptions : INestedOptions /// NU, NZ, OM, PA, PE, PF, PG, PH, /// PK, PL, PM, PN, PR, PS, PT, PY, /// QA, RE, RO, RS, RU, RW, SA, SB, - /// SC, SE, SG, SH, SI, SJ, SK, SL, - /// SM, SN, SO, SR, SS, ST, SV, SX, - /// SZ, TA, TC, TD, TF, TG, TH, TJ, - /// TK, TL, TM, TN, TO, TR, TT, TV, - /// TW, TZ, UA, UG, US, UY, UZ, VA, - /// VC, VE, VG, VN, VU, WF, WS, XK, - /// YE, YT, ZA, ZM, ZW, or ZZ. + /// SC, SD, SE, SG, SH, SI, SJ, SK, + /// SL, SM, SN, SO, SR, SS, ST, SV, + /// SX, SZ, TA, TC, TD, TF, TG, TH, + /// TJ, TK, TL, TM, TN, TO, TR, TT, + /// TV, TW, TZ, UA, UG, US, UY, UZ, + /// VA, VC, VE, VG, VN, VU, WF, WS, + /// XK, YE, YT, ZA, ZM, ZW, or ZZ. /// [JsonProperty("allowed_countries")] #if NET6_0_OR_GREATER From b7526104d2e7a994c8bd528640865978fb5acd0f Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Tue, 14 Jan 2025 20:50:09 +0000 Subject: [PATCH 07/17] Update generated code for v1446 --- OPENAPI_VERSION | 2 +- .../Entities/Checkout/Sessions/Session.cs | 9 ++ .../Checkout/Sessions/SessionDiscount.cs | 97 +++++++++++++++++++ 3 files changed, 107 insertions(+), 1 deletion(-) create mode 100644 src/Stripe.net/Entities/Checkout/Sessions/SessionDiscount.cs diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 53bf35301..0e6ebdfc2 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1444 \ No newline at end of file +v1446 \ No newline at end of file diff --git a/src/Stripe.net/Entities/Checkout/Sessions/Session.cs b/src/Stripe.net/Entities/Checkout/Sessions/Session.cs index 3b601ba7a..dda9ba0e5 100644 --- a/src/Stripe.net/Entities/Checkout/Sessions/Session.cs +++ b/src/Stripe.net/Entities/Checkout/Sessions/Session.cs @@ -303,6 +303,15 @@ public Customer Customer #endif public string CustomerEmail { get; set; } + /// + /// List of coupons and promotion codes attached to the Checkout Session. + /// + [JsonProperty("discounts")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("discounts")] +#endif + public List Discounts { get; set; } + /// /// The timestamp at which the Checkout Session will expire. /// diff --git a/src/Stripe.net/Entities/Checkout/Sessions/SessionDiscount.cs b/src/Stripe.net/Entities/Checkout/Sessions/SessionDiscount.cs new file mode 100644 index 000000000..aecbe11f9 --- /dev/null +++ b/src/Stripe.net/Entities/Checkout/Sessions/SessionDiscount.cs @@ -0,0 +1,97 @@ +// File generated from our OpenAPI spec +namespace Stripe.Checkout +{ + using Newtonsoft.Json; + using Stripe.Infrastructure; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + +#if NET6_0_OR_GREATER + [STJS.JsonConverter(typeof(STJMemberSerializationOptIn))] +#endif + public class SessionDiscount : StripeEntity + { + #region Expandable Coupon + + /// + /// (ID of the Coupon) + /// Coupon attached to the Checkout Session. + /// + [JsonIgnore] +#if NET6_0_OR_GREATER + [STJS.JsonIgnore] +#endif + public string CouponId + { + get => this.InternalCoupon?.Id; + set => this.InternalCoupon = SetExpandableFieldId(value, this.InternalCoupon); + } + + /// + /// (Expanded) + /// Coupon attached to the Checkout Session. + /// + /// For more information, see the expand documentation. + /// + [JsonIgnore] +#if NET6_0_OR_GREATER + [STJS.JsonIgnore] +#endif + public Coupon Coupon + { + get => this.InternalCoupon?.ExpandedObject; + set => this.InternalCoupon = SetExpandableFieldObject(value, this.InternalCoupon); + } + + [JsonProperty("coupon")] + [JsonConverter(typeof(ExpandableFieldConverter))] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("coupon")] + [STJS.JsonConverter(typeof(STJExpandableFieldConverter))] +#endif + internal ExpandableField InternalCoupon { get; set; } + #endregion + + #region Expandable PromotionCode + + /// + /// (ID of the PromotionCode) + /// Promotion code attached to the Checkout Session. + /// + [JsonIgnore] +#if NET6_0_OR_GREATER + [STJS.JsonIgnore] +#endif + public string PromotionCodeId + { + get => this.InternalPromotionCode?.Id; + set => this.InternalPromotionCode = SetExpandableFieldId(value, this.InternalPromotionCode); + } + + /// + /// (Expanded) + /// Promotion code attached to the Checkout Session. + /// + /// For more information, see the expand documentation. + /// + [JsonIgnore] +#if NET6_0_OR_GREATER + [STJS.JsonIgnore] +#endif + public PromotionCode PromotionCode + { + get => this.InternalPromotionCode?.ExpandedObject; + set => this.InternalPromotionCode = SetExpandableFieldObject(value, this.InternalPromotionCode); + } + + [JsonProperty("promotion_code")] + [JsonConverter(typeof(ExpandableFieldConverter))] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("promotion_code")] + [STJS.JsonConverter(typeof(STJExpandableFieldConverter))] +#endif + internal ExpandableField InternalPromotionCode { get; set; } + #endregion + } +} From a273a3f7b27d27459ebe79205b3803e10f68ab39 Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Wed, 15 Jan 2025 19:15:00 +0000 Subject: [PATCH 08/17] Update generated code for v1448 --- OPENAPI_VERSION | 2 +- .../Charges/ChargePaymentMethodDetails.cs | 6 +++ .../ChargePaymentMethodDetailsPayByBank.cs | 7 ++++ .../ConfirmationTokenPaymentMethodPreview.cs | 15 +++++-- ...ationTokenPaymentMethodPreviewPayByBank.cs | 7 ++++ .../PaymentIntentPaymentMethodOptions.cs | 6 +++ ...mentIntentPaymentMethodOptionsPayByBank.cs | 7 ++++ .../Entities/PaymentLinks/PaymentLink.cs | 8 ++-- .../PaymentMethodConfiguration.cs | 6 +++ .../PaymentMethodConfigurationPayByBank.cs | 27 ++++++++++++ ...ConfigurationPayByBankDisplayPreference.cs | 41 +++++++++++++++++++ .../Entities/PaymentMethods/PaymentMethod.cs | 15 +++++-- .../PaymentMethods/PaymentMethodPayByBank.cs | 7 ++++ .../Checkout/Sessions/SessionCreateOptions.cs | 10 ++--- .../SessionPaymentMethodOptionsOptions.cs | 9 ++++ ...ionPaymentMethodOptionsPayByBankOptions.cs | 7 ++++ .../CustomerPaymentMethodListOptions.cs | 6 +-- .../PaymentIntentPaymentMethodDataOptions.cs | 20 ++++++--- ...IntentPaymentMethodDataPayByBankOptions.cs | 7 ++++ ...aymentIntentPaymentMethodOptionsOptions.cs | 10 +++++ ...entPaymentMethodOptionsPayByBankOptions.cs | 7 ++++ .../PaymentLinks/PaymentLinkCreateOptions.cs | 8 ++-- .../PaymentLinks/PaymentLinkUpdateOptions.cs | 8 ++-- ...PaymentMethodConfigurationCreateOptions.cs | 12 ++++++ ...rationPayByBankDisplayPreferenceOptions.cs | 21 ++++++++++ ...mentMethodConfigurationPayByBankOptions.cs | 20 +++++++++ ...PaymentMethodConfigurationUpdateOptions.cs | 12 ++++++ .../PaymentMethodCreateOptions.cs | 16 ++++++-- .../PaymentMethodListOptions.cs | 6 +-- .../PaymentMethodPayByBankOptions.cs | 7 ++++ .../PaymentMethodUpdateOptions.cs | 10 +++++ .../SetupIntentPaymentMethodDataOptions.cs | 20 ++++++--- ...IntentPaymentMethodDataPayByBankOptions.cs | 7 ++++ ...nfirmationTokenPaymentMethodDataOptions.cs | 20 ++++++--- ...nTokenPaymentMethodDataPayByBankOptions.cs | 7 ++++ 35 files changed, 354 insertions(+), 50 deletions(-) create mode 100644 src/Stripe.net/Entities/Charges/ChargePaymentMethodDetailsPayByBank.cs create mode 100644 src/Stripe.net/Entities/ConfirmationTokens/ConfirmationTokenPaymentMethodPreviewPayByBank.cs create mode 100644 src/Stripe.net/Entities/PaymentIntents/PaymentIntentPaymentMethodOptionsPayByBank.cs create mode 100644 src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfigurationPayByBank.cs create mode 100644 src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfigurationPayByBankDisplayPreference.cs create mode 100644 src/Stripe.net/Entities/PaymentMethods/PaymentMethodPayByBank.cs create mode 100644 src/Stripe.net/Services/Checkout/Sessions/SessionPaymentMethodOptionsPayByBankOptions.cs create mode 100644 src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodDataPayByBankOptions.cs create mode 100644 src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodOptionsPayByBankOptions.cs create mode 100644 src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationPayByBankDisplayPreferenceOptions.cs create mode 100644 src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationPayByBankOptions.cs create mode 100644 src/Stripe.net/Services/PaymentMethods/PaymentMethodPayByBankOptions.cs create mode 100644 src/Stripe.net/Services/SetupIntents/SetupIntentPaymentMethodDataPayByBankOptions.cs create mode 100644 src/Stripe.net/Services/TestHelpers/ConfirmationTokens/ConfirmationTokenPaymentMethodDataPayByBankOptions.cs diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 0e6ebdfc2..41237ba54 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1446 \ No newline at end of file +v1448 \ No newline at end of file diff --git a/src/Stripe.net/Entities/Charges/ChargePaymentMethodDetails.cs b/src/Stripe.net/Entities/Charges/ChargePaymentMethodDetails.cs index 8b06bd857..b15336a93 100644 --- a/src/Stripe.net/Entities/Charges/ChargePaymentMethodDetails.cs +++ b/src/Stripe.net/Entities/Charges/ChargePaymentMethodDetails.cs @@ -224,6 +224,12 @@ public class ChargePaymentMethodDetails : StripeEntity + { + } +} diff --git a/src/Stripe.net/Entities/ConfirmationTokens/ConfirmationTokenPaymentMethodPreview.cs b/src/Stripe.net/Entities/ConfirmationTokens/ConfirmationTokenPaymentMethodPreview.cs index 037034387..a8727f7e9 100644 --- a/src/Stripe.net/Entities/ConfirmationTokens/ConfirmationTokenPaymentMethodPreview.cs +++ b/src/Stripe.net/Entities/ConfirmationTokens/ConfirmationTokenPaymentMethodPreview.cs @@ -278,6 +278,12 @@ public Customer Customer #endif public ConfirmationTokenPaymentMethodPreviewP24 P24 { get; set; } + [JsonProperty("pay_by_bank")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("pay_by_bank")] +#endif + public ConfirmationTokenPaymentMethodPreviewPayByBank PayByBank { get; set; } + [JsonProperty("payco")] #if NET6_0_OR_GREATER [STJS.JsonPropertyName("payco")] @@ -379,10 +385,11 @@ public Customer Customer /// gopay, grabpay, id_bank_transfer, ideal, /// interac_present, kakao_pay, klarna, konbini, kr_card, /// link, mb_way, mobilepay, multibanco, naver_pay, - /// oxxo, p24, payco, paynow, paypal, payto, - /// pix, promptpay, qris, rechnung, revolut_pay, - /// samsung_pay, sepa_debit, shopeepay, sofort, swish, - /// twint, us_bank_account, wechat_pay, or zip. + /// oxxo, p24, pay_by_bank, payco, paynow, paypal, + /// payto, pix, promptpay, qris, rechnung, + /// revolut_pay, samsung_pay, sepa_debit, shopeepay, + /// sofort, swish, twint, us_bank_account, wechat_pay, or + /// zip. /// [JsonProperty("type")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/ConfirmationTokens/ConfirmationTokenPaymentMethodPreviewPayByBank.cs b/src/Stripe.net/Entities/ConfirmationTokens/ConfirmationTokenPaymentMethodPreviewPayByBank.cs new file mode 100644 index 000000000..c99371f61 --- /dev/null +++ b/src/Stripe.net/Entities/ConfirmationTokens/ConfirmationTokenPaymentMethodPreviewPayByBank.cs @@ -0,0 +1,7 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + public class ConfirmationTokenPaymentMethodPreviewPayByBank : StripeEntity + { + } +} diff --git a/src/Stripe.net/Entities/PaymentIntents/PaymentIntentPaymentMethodOptions.cs b/src/Stripe.net/Entities/PaymentIntents/PaymentIntentPaymentMethodOptions.cs index aba50155c..822db2f95 100644 --- a/src/Stripe.net/Entities/PaymentIntents/PaymentIntentPaymentMethodOptions.cs +++ b/src/Stripe.net/Entities/PaymentIntents/PaymentIntentPaymentMethodOptions.cs @@ -212,6 +212,12 @@ public class PaymentIntentPaymentMethodOptions : StripeEntity + { + } +} diff --git a/src/Stripe.net/Entities/PaymentLinks/PaymentLink.cs b/src/Stripe.net/Entities/PaymentLinks/PaymentLink.cs index a9bd6e87e..064d58909 100644 --- a/src/Stripe.net/Entities/PaymentLinks/PaymentLink.cs +++ b/src/Stripe.net/Entities/PaymentLinks/PaymentLink.cs @@ -314,10 +314,10 @@ public Account OnBehalfOf /// au_becs_debit, bacs_debit, bancontact, blik, boleto, /// card, cashapp, eps, fpx, giropay, gopay, /// grabpay, ideal, klarna, konbini, link, mb_way, - /// mobilepay, multibanco, oxxo, p24, paynow, - /// paypal, payto, pix, promptpay, qris, rechnung, - /// sepa_debit, shopeepay, sofort, swish, twint, - /// us_bank_account, wechat_pay, or zip. + /// mobilepay, multibanco, oxxo, p24, pay_by_bank, + /// paynow, paypal, payto, pix, promptpay, qris, + /// rechnung, sepa_debit, shopeepay, sofort, swish, + /// twint, us_bank_account, wechat_pay, or zip. /// [JsonProperty("payment_method_types")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfiguration.cs b/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfiguration.cs index f5e8f17ca..b97b52854 100644 --- a/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfiguration.cs +++ b/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfiguration.cs @@ -304,6 +304,12 @@ public class PaymentMethodConfiguration : StripeEntity + { + /// + /// Whether this payment method may be offered at checkout. True if + /// display_preference is on and the payment method's capability is active. + /// + [JsonProperty("available")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("available")] +#endif + public bool Available { get; set; } + + [JsonProperty("display_preference")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("display_preference")] +#endif + public PaymentMethodConfigurationPayByBankDisplayPreference DisplayPreference { get; set; } + } +} diff --git a/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfigurationPayByBankDisplayPreference.cs b/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfigurationPayByBankDisplayPreference.cs new file mode 100644 index 000000000..8f1f8fcd7 --- /dev/null +++ b/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfigurationPayByBankDisplayPreference.cs @@ -0,0 +1,41 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class PaymentMethodConfigurationPayByBankDisplayPreference : StripeEntity + { + /// + /// For child configs, whether or not the account's preference will be observed. If + /// false, the parent configuration's default is used. + /// + [JsonProperty("overridable")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("overridable")] +#endif + public bool? Overridable { get; set; } + + /// + /// The account's display preference. + /// One of: none, off, or on. + /// + [JsonProperty("preference")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("preference")] +#endif + public string Preference { get; set; } + + /// + /// The effective display preference value. + /// One of: off, or on. + /// + [JsonProperty("value")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("value")] +#endif + public string Value { get; set; } + } +} diff --git a/src/Stripe.net/Entities/PaymentMethods/PaymentMethod.cs b/src/Stripe.net/Entities/PaymentMethods/PaymentMethod.cs index 6badec661..865a0e298 100644 --- a/src/Stripe.net/Entities/PaymentMethods/PaymentMethod.cs +++ b/src/Stripe.net/Entities/PaymentMethods/PaymentMethod.cs @@ -340,6 +340,12 @@ public Customer Customer #endif public PaymentMethodP24 P24 { get; set; } + [JsonProperty("pay_by_bank")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("pay_by_bank")] +#endif + public PaymentMethodPayByBank PayByBank { get; set; } + [JsonProperty("payco")] #if NET6_0_OR_GREATER [STJS.JsonPropertyName("payco")] @@ -452,10 +458,11 @@ public Customer Customer /// gopay, grabpay, id_bank_transfer, ideal, /// interac_present, kakao_pay, klarna, konbini, kr_card, /// link, mb_way, mobilepay, multibanco, naver_pay, - /// oxxo, p24, payco, paynow, paypal, payto, - /// pix, promptpay, qris, rechnung, revolut_pay, - /// samsung_pay, sepa_debit, shopeepay, sofort, swish, - /// twint, us_bank_account, wechat_pay, or zip. + /// oxxo, p24, pay_by_bank, payco, paynow, paypal, + /// payto, pix, promptpay, qris, rechnung, + /// revolut_pay, samsung_pay, sepa_debit, shopeepay, + /// sofort, swish, twint, us_bank_account, wechat_pay, or + /// zip. /// [JsonProperty("type")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/PaymentMethods/PaymentMethodPayByBank.cs b/src/Stripe.net/Entities/PaymentMethods/PaymentMethodPayByBank.cs new file mode 100644 index 000000000..4f5bf6eb8 --- /dev/null +++ b/src/Stripe.net/Entities/PaymentMethods/PaymentMethodPayByBank.cs @@ -0,0 +1,7 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + public class PaymentMethodPayByBank : StripeEntity + { + } +} diff --git a/src/Stripe.net/Services/Checkout/Sessions/SessionCreateOptions.cs b/src/Stripe.net/Services/Checkout/Sessions/SessionCreateOptions.cs index e2fe75209..55b2da5ae 100644 --- a/src/Stripe.net/Services/Checkout/Sessions/SessionCreateOptions.cs +++ b/src/Stripe.net/Services/Checkout/Sessions/SessionCreateOptions.cs @@ -364,11 +364,11 @@ public class SessionCreateOptions : BaseOptions, IHasMetadata /// customer_balance, eps, fpx, giropay, gopay, /// grabpay, ideal, kakao_pay, klarna, konbini, /// kr_card, link, mb_way, mobilepay, multibanco, - /// naver_pay, oxxo, p24, payco, paynow, paypal, - /// payto, pix, promptpay, qris, rechnung, - /// revolut_pay, samsung_pay, sepa_debit, shopeepay, - /// sofort, swish, twint, us_bank_account, wechat_pay, or - /// zip. + /// naver_pay, oxxo, p24, pay_by_bank, payco, + /// paynow, paypal, payto, pix, promptpay, qris, + /// rechnung, revolut_pay, samsung_pay, sepa_debit, + /// shopeepay, sofort, swish, twint, us_bank_account, + /// wechat_pay, or zip. /// [JsonProperty("payment_method_types")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/Checkout/Sessions/SessionPaymentMethodOptionsOptions.cs b/src/Stripe.net/Services/Checkout/Sessions/SessionPaymentMethodOptionsOptions.cs index eae7d0628..f759aa7ac 100644 --- a/src/Stripe.net/Services/Checkout/Sessions/SessionPaymentMethodOptionsOptions.cs +++ b/src/Stripe.net/Services/Checkout/Sessions/SessionPaymentMethodOptionsOptions.cs @@ -251,6 +251,15 @@ public class SessionPaymentMethodOptionsOptions : INestedOptions #endif public SessionPaymentMethodOptionsP24Options P24 { get; set; } + /// + /// contains details about the Pay By Bank payment method options. + /// + [JsonProperty("pay_by_bank")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("pay_by_bank")] +#endif + public SessionPaymentMethodOptionsPayByBankOptions PayByBank { get; set; } + /// /// contains details about the PAYCO payment method options. /// diff --git a/src/Stripe.net/Services/Checkout/Sessions/SessionPaymentMethodOptionsPayByBankOptions.cs b/src/Stripe.net/Services/Checkout/Sessions/SessionPaymentMethodOptionsPayByBankOptions.cs new file mode 100644 index 000000000..0e3e2e486 --- /dev/null +++ b/src/Stripe.net/Services/Checkout/Sessions/SessionPaymentMethodOptionsPayByBankOptions.cs @@ -0,0 +1,7 @@ +// File generated from our OpenAPI spec +namespace Stripe.Checkout +{ + public class SessionPaymentMethodOptionsPayByBankOptions : INestedOptions + { + } +} diff --git a/src/Stripe.net/Services/CustomerPaymentMethods/CustomerPaymentMethodListOptions.cs b/src/Stripe.net/Services/CustomerPaymentMethods/CustomerPaymentMethodListOptions.cs index 5fd96f183..2e55e73b3 100644 --- a/src/Stripe.net/Services/CustomerPaymentMethods/CustomerPaymentMethodListOptions.cs +++ b/src/Stripe.net/Services/CustomerPaymentMethods/CustomerPaymentMethodListOptions.cs @@ -32,9 +32,9 @@ public class CustomerPaymentMethodListOptions : ListOptions /// customer_balance, eps, fpx, giropay, gopay, /// grabpay, id_bank_transfer, ideal, kakao_pay, klarna, /// konbini, kr_card, link, mb_way, mobilepay, - /// multibanco, naver_pay, oxxo, p24, payco, - /// paynow, paypal, payto, pix, promptpay, qris, - /// rechnung, revolut_pay, samsung_pay, sepa_debit, + /// multibanco, naver_pay, oxxo, p24, pay_by_bank, + /// payco, paynow, paypal, payto, pix, promptpay, + /// qris, rechnung, revolut_pay, samsung_pay, sepa_debit, /// shopeepay, sofort, swish, twint, us_bank_account, /// wechat_pay, or zip. /// diff --git a/src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodDataOptions.cs b/src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodDataOptions.cs index bba49f7d0..87aada781 100644 --- a/src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodDataOptions.cs +++ b/src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodDataOptions.cs @@ -364,6 +364,16 @@ public class PaymentIntentPaymentMethodDataOptions : INestedOptions, IHasMetadat #endif public PaymentIntentPaymentMethodDataP24Options P24 { get; set; } + /// + /// If this is a pay_by_bank PaymentMethod, this hash contains details about the + /// PayByBank payment method. + /// + [JsonProperty("pay_by_bank")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("pay_by_bank")] +#endif + public PaymentIntentPaymentMethodDataPayByBankOptions PayByBank { get; set; } + /// /// If this is a payco PaymentMethod, this hash contains details about the PAYCO /// payment method. @@ -535,11 +545,11 @@ public class PaymentIntentPaymentMethodDataOptions : INestedOptions, IHasMetadat /// eps, fpx, giropay, gopay, grabpay, /// id_bank_transfer, ideal, kakao_pay, klarna, konbini, /// kr_card, link, mb_way, mobilepay, multibanco, - /// naver_pay, oxxo, p24, payco, paynow, paypal, - /// payto, pix, promptpay, qris, rechnung, - /// revolut_pay, samsung_pay, sepa_debit, shopeepay, - /// sofort, swish, twint, us_bank_account, wechat_pay, or - /// zip. + /// naver_pay, oxxo, p24, pay_by_bank, payco, + /// paynow, paypal, payto, pix, promptpay, qris, + /// rechnung, revolut_pay, samsung_pay, sepa_debit, + /// shopeepay, sofort, swish, twint, us_bank_account, + /// wechat_pay, or zip. /// [JsonProperty("type")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodDataPayByBankOptions.cs b/src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodDataPayByBankOptions.cs new file mode 100644 index 000000000..878356049 --- /dev/null +++ b/src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodDataPayByBankOptions.cs @@ -0,0 +1,7 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + public class PaymentIntentPaymentMethodDataPayByBankOptions : INestedOptions + { + } +} diff --git a/src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodOptionsOptions.cs b/src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodOptionsOptions.cs index 8401d675a..b653b5395 100644 --- a/src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodOptionsOptions.cs +++ b/src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodOptionsOptions.cs @@ -347,6 +347,16 @@ public class PaymentIntentPaymentMethodOptionsOptions : INestedOptions #endif public PaymentIntentPaymentMethodOptionsP24Options P24 { get; set; } + /// + /// If this is a pay_by_bank PaymentMethod, this sub-hash contains details about the + /// PayByBank payment method options. + /// + [JsonProperty("pay_by_bank")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("pay_by_bank")] +#endif + public PaymentIntentPaymentMethodOptionsPayByBankOptions PayByBank { get; set; } + /// /// If this is a payco PaymentMethod, this sub-hash contains details about the PAYCO /// payment method options. diff --git a/src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodOptionsPayByBankOptions.cs b/src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodOptionsPayByBankOptions.cs new file mode 100644 index 000000000..052ca6b7a --- /dev/null +++ b/src/Stripe.net/Services/PaymentIntents/PaymentIntentPaymentMethodOptionsPayByBankOptions.cs @@ -0,0 +1,7 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + public class PaymentIntentPaymentMethodOptionsPayByBankOptions : INestedOptions + { + } +} diff --git a/src/Stripe.net/Services/PaymentLinks/PaymentLinkCreateOptions.cs b/src/Stripe.net/Services/PaymentLinks/PaymentLinkCreateOptions.cs index 19e40f5ab..a7fc1e514 100644 --- a/src/Stripe.net/Services/PaymentLinks/PaymentLinkCreateOptions.cs +++ b/src/Stripe.net/Services/PaymentLinks/PaymentLinkCreateOptions.cs @@ -212,10 +212,10 @@ public class PaymentLinkCreateOptions : BaseOptions, IHasMetadata /// au_becs_debit, bacs_debit, bancontact, blik, boleto, /// card, cashapp, eps, fpx, giropay, gopay, /// grabpay, ideal, klarna, konbini, link, mb_way, - /// mobilepay, multibanco, oxxo, p24, paynow, - /// paypal, payto, pix, promptpay, qris, rechnung, - /// sepa_debit, shopeepay, sofort, swish, twint, - /// us_bank_account, wechat_pay, or zip. + /// mobilepay, multibanco, oxxo, p24, pay_by_bank, + /// paynow, paypal, payto, pix, promptpay, qris, + /// rechnung, sepa_debit, shopeepay, sofort, swish, + /// twint, us_bank_account, wechat_pay, or zip. /// [JsonProperty("payment_method_types")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/PaymentLinks/PaymentLinkUpdateOptions.cs b/src/Stripe.net/Services/PaymentLinks/PaymentLinkUpdateOptions.cs index d19844a13..ebd45b4e3 100644 --- a/src/Stripe.net/Services/PaymentLinks/PaymentLinkUpdateOptions.cs +++ b/src/Stripe.net/Services/PaymentLinks/PaymentLinkUpdateOptions.cs @@ -169,10 +169,10 @@ public class PaymentLinkUpdateOptions : BaseOptions, IHasMetadata /// au_becs_debit, bacs_debit, bancontact, blik, boleto, /// card, cashapp, eps, fpx, giropay, gopay, /// grabpay, ideal, klarna, konbini, link, mb_way, - /// mobilepay, multibanco, oxxo, p24, paynow, - /// paypal, payto, pix, promptpay, qris, rechnung, - /// sepa_debit, shopeepay, sofort, swish, twint, - /// us_bank_account, wechat_pay, or zip. + /// mobilepay, multibanco, oxxo, p24, pay_by_bank, + /// paynow, paypal, payto, pix, promptpay, qris, + /// rechnung, sepa_debit, shopeepay, sofort, swish, + /// twint, us_bank_account, wechat_pay, or zip. /// [JsonProperty("payment_method_types")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationCreateOptions.cs b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationCreateOptions.cs index da1fae9a5..f48aa7433 100644 --- a/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationCreateOptions.cs +++ b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationCreateOptions.cs @@ -425,6 +425,18 @@ public class PaymentMethodConfigurationCreateOptions : BaseOptions #endif public string Parent { get; set; } + /// + /// Pay by bank is a redirect payment method backed by bank transfers. A customer is + /// redirected to their bank to authorize a bank transfer for a given amount. This removes a + /// lot of the error risks inherent in waiting for the customer to initiate a transfer + /// themselves, and is less expensive than card payments. + /// + [JsonProperty("pay_by_bank")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("pay_by_bank")] +#endif + public PaymentMethodConfigurationPayByBankOptions PayByBank { get; set; } + /// /// PayNow is a Singapore-based payment method that allows customers to make a payment using /// their preferred app from participating banks and participating non-bank financial diff --git a/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationPayByBankDisplayPreferenceOptions.cs b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationPayByBankDisplayPreferenceOptions.cs new file mode 100644 index 000000000..f0e7d8941 --- /dev/null +++ b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationPayByBankDisplayPreferenceOptions.cs @@ -0,0 +1,21 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class PaymentMethodConfigurationPayByBankDisplayPreferenceOptions : INestedOptions + { + /// + /// The account's preference for whether or not to display this payment method. + /// One of: none, off, or on. + /// + [JsonProperty("preference")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("preference")] +#endif + public string Preference { get; set; } + } +} diff --git a/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationPayByBankOptions.cs b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationPayByBankOptions.cs new file mode 100644 index 000000000..6580c05d7 --- /dev/null +++ b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationPayByBankOptions.cs @@ -0,0 +1,20 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class PaymentMethodConfigurationPayByBankOptions : INestedOptions + { + /// + /// Whether or not the payment method should be displayed. + /// + [JsonProperty("display_preference")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("display_preference")] +#endif + public PaymentMethodConfigurationPayByBankDisplayPreferenceOptions DisplayPreference { get; set; } + } +} diff --git a/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationUpdateOptions.cs b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationUpdateOptions.cs index 233bd605d..728cda076 100644 --- a/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationUpdateOptions.cs +++ b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationUpdateOptions.cs @@ -425,6 +425,18 @@ public class PaymentMethodConfigurationUpdateOptions : BaseOptions #endif public PaymentMethodConfigurationP24Options P24 { get; set; } + /// + /// Pay by bank is a redirect payment method backed by bank transfers. A customer is + /// redirected to their bank to authorize a bank transfer for a given amount. This removes a + /// lot of the error risks inherent in waiting for the customer to initiate a transfer + /// themselves, and is less expensive than card payments. + /// + [JsonProperty("pay_by_bank")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("pay_by_bank")] +#endif + public PaymentMethodConfigurationPayByBankOptions PayByBank { get; set; } + /// /// PayNow is a Singapore-based payment method that allows customers to make a payment using /// their preferred app from participating banks and participating non-bank financial diff --git a/src/Stripe.net/Services/PaymentMethods/PaymentMethodCreateOptions.cs b/src/Stripe.net/Services/PaymentMethods/PaymentMethodCreateOptions.cs index 99ec30043..a2ef7dc8f 100644 --- a/src/Stripe.net/Services/PaymentMethods/PaymentMethodCreateOptions.cs +++ b/src/Stripe.net/Services/PaymentMethods/PaymentMethodCreateOptions.cs @@ -388,6 +388,16 @@ public class PaymentMethodCreateOptions : BaseOptions, IHasMetadata #endif public PaymentMethodP24Options P24 { get; set; } + /// + /// If this is a pay_by_bank PaymentMethod, this hash contains details about the + /// PayByBank payment method. + /// + [JsonProperty("pay_by_bank")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("pay_by_bank")] +#endif + public PaymentMethodPayByBankOptions PayByBank { get; set; } + /// /// If this is a payco PaymentMethod, this hash contains details about the PAYCO /// payment method. @@ -568,9 +578,9 @@ public class PaymentMethodCreateOptions : BaseOptions, IHasMetadata /// customer_balance, eps, fpx, giropay, gopay, /// grabpay, id_bank_transfer, ideal, kakao_pay, klarna, /// konbini, kr_card, link, mb_way, mobilepay, - /// multibanco, naver_pay, oxxo, p24, payco, - /// paynow, paypal, payto, pix, promptpay, qris, - /// rechnung, revolut_pay, samsung_pay, sepa_debit, + /// multibanco, naver_pay, oxxo, p24, pay_by_bank, + /// payco, paynow, paypal, payto, pix, promptpay, + /// qris, rechnung, revolut_pay, samsung_pay, sepa_debit, /// shopeepay, sofort, swish, twint, us_bank_account, /// wechat_pay, or zip. /// diff --git a/src/Stripe.net/Services/PaymentMethods/PaymentMethodListOptions.cs b/src/Stripe.net/Services/PaymentMethods/PaymentMethodListOptions.cs index 9374ab4c3..495cdf332 100644 --- a/src/Stripe.net/Services/PaymentMethods/PaymentMethodListOptions.cs +++ b/src/Stripe.net/Services/PaymentMethods/PaymentMethodListOptions.cs @@ -28,9 +28,9 @@ public class PaymentMethodListOptions : ListOptions /// customer_balance, eps, fpx, giropay, gopay, /// grabpay, id_bank_transfer, ideal, kakao_pay, klarna, /// konbini, kr_card, link, mb_way, mobilepay, - /// multibanco, naver_pay, oxxo, p24, payco, - /// paynow, paypal, payto, pix, promptpay, qris, - /// rechnung, revolut_pay, samsung_pay, sepa_debit, + /// multibanco, naver_pay, oxxo, p24, pay_by_bank, + /// payco, paynow, paypal, payto, pix, promptpay, + /// qris, rechnung, revolut_pay, samsung_pay, sepa_debit, /// shopeepay, sofort, swish, twint, us_bank_account, /// wechat_pay, or zip. /// diff --git a/src/Stripe.net/Services/PaymentMethods/PaymentMethodPayByBankOptions.cs b/src/Stripe.net/Services/PaymentMethods/PaymentMethodPayByBankOptions.cs new file mode 100644 index 000000000..7ea843861 --- /dev/null +++ b/src/Stripe.net/Services/PaymentMethods/PaymentMethodPayByBankOptions.cs @@ -0,0 +1,7 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + public class PaymentMethodPayByBankOptions : INestedOptions + { + } +} diff --git a/src/Stripe.net/Services/PaymentMethods/PaymentMethodUpdateOptions.cs b/src/Stripe.net/Services/PaymentMethods/PaymentMethodUpdateOptions.cs index 928e0610f..c156a44b2 100644 --- a/src/Stripe.net/Services/PaymentMethods/PaymentMethodUpdateOptions.cs +++ b/src/Stripe.net/Services/PaymentMethods/PaymentMethodUpdateOptions.cs @@ -73,6 +73,16 @@ public class PaymentMethodUpdateOptions : BaseOptions, IHasMetadata #endif public PaymentMethodNaverPayOptions NaverPay { get; set; } + /// + /// If this is a pay_by_bank PaymentMethod, this hash contains details about the + /// PayByBank payment method. + /// + [JsonProperty("pay_by_bank")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("pay_by_bank")] +#endif + public PaymentMethodPayByBankOptions PayByBank { get; set; } + /// /// If this is a payto PaymentMethod, this hash contains details about the PayTo /// payment method. diff --git a/src/Stripe.net/Services/SetupIntents/SetupIntentPaymentMethodDataOptions.cs b/src/Stripe.net/Services/SetupIntents/SetupIntentPaymentMethodDataOptions.cs index 61c8626d0..2f64b8c91 100644 --- a/src/Stripe.net/Services/SetupIntents/SetupIntentPaymentMethodDataOptions.cs +++ b/src/Stripe.net/Services/SetupIntents/SetupIntentPaymentMethodDataOptions.cs @@ -364,6 +364,16 @@ public class SetupIntentPaymentMethodDataOptions : INestedOptions, IHasMetadata #endif public SetupIntentPaymentMethodDataP24Options P24 { get; set; } + /// + /// If this is a pay_by_bank PaymentMethod, this hash contains details about the + /// PayByBank payment method. + /// + [JsonProperty("pay_by_bank")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("pay_by_bank")] +#endif + public SetupIntentPaymentMethodDataPayByBankOptions PayByBank { get; set; } + /// /// If this is a payco PaymentMethod, this hash contains details about the PAYCO /// payment method. @@ -535,11 +545,11 @@ public class SetupIntentPaymentMethodDataOptions : INestedOptions, IHasMetadata /// eps, fpx, giropay, gopay, grabpay, /// id_bank_transfer, ideal, kakao_pay, klarna, konbini, /// kr_card, link, mb_way, mobilepay, multibanco, - /// naver_pay, oxxo, p24, payco, paynow, paypal, - /// payto, pix, promptpay, qris, rechnung, - /// revolut_pay, samsung_pay, sepa_debit, shopeepay, - /// sofort, swish, twint, us_bank_account, wechat_pay, or - /// zip. + /// naver_pay, oxxo, p24, pay_by_bank, payco, + /// paynow, paypal, payto, pix, promptpay, qris, + /// rechnung, revolut_pay, samsung_pay, sepa_debit, + /// shopeepay, sofort, swish, twint, us_bank_account, + /// wechat_pay, or zip. /// [JsonProperty("type")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/SetupIntents/SetupIntentPaymentMethodDataPayByBankOptions.cs b/src/Stripe.net/Services/SetupIntents/SetupIntentPaymentMethodDataPayByBankOptions.cs new file mode 100644 index 000000000..182909a78 --- /dev/null +++ b/src/Stripe.net/Services/SetupIntents/SetupIntentPaymentMethodDataPayByBankOptions.cs @@ -0,0 +1,7 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + public class SetupIntentPaymentMethodDataPayByBankOptions : INestedOptions + { + } +} diff --git a/src/Stripe.net/Services/TestHelpers/ConfirmationTokens/ConfirmationTokenPaymentMethodDataOptions.cs b/src/Stripe.net/Services/TestHelpers/ConfirmationTokens/ConfirmationTokenPaymentMethodDataOptions.cs index cd7827cac..7ec250034 100644 --- a/src/Stripe.net/Services/TestHelpers/ConfirmationTokens/ConfirmationTokenPaymentMethodDataOptions.cs +++ b/src/Stripe.net/Services/TestHelpers/ConfirmationTokens/ConfirmationTokenPaymentMethodDataOptions.cs @@ -364,6 +364,16 @@ public class ConfirmationTokenPaymentMethodDataOptions : INestedOptions, IHasMet #endif public ConfirmationTokenPaymentMethodDataP24Options P24 { get; set; } + /// + /// If this is a pay_by_bank PaymentMethod, this hash contains details about the + /// PayByBank payment method. + /// + [JsonProperty("pay_by_bank")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("pay_by_bank")] +#endif + public ConfirmationTokenPaymentMethodDataPayByBankOptions PayByBank { get; set; } + /// /// If this is a payco PaymentMethod, this hash contains details about the PAYCO /// payment method. @@ -535,11 +545,11 @@ public class ConfirmationTokenPaymentMethodDataOptions : INestedOptions, IHasMet /// eps, fpx, giropay, gopay, grabpay, /// id_bank_transfer, ideal, kakao_pay, klarna, konbini, /// kr_card, link, mb_way, mobilepay, multibanco, - /// naver_pay, oxxo, p24, payco, paynow, paypal, - /// payto, pix, promptpay, qris, rechnung, - /// revolut_pay, samsung_pay, sepa_debit, shopeepay, - /// sofort, swish, twint, us_bank_account, wechat_pay, or - /// zip. + /// naver_pay, oxxo, p24, pay_by_bank, payco, + /// paynow, paypal, payto, pix, promptpay, qris, + /// rechnung, revolut_pay, samsung_pay, sepa_debit, + /// shopeepay, sofort, swish, twint, us_bank_account, + /// wechat_pay, or zip. /// [JsonProperty("type")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/TestHelpers/ConfirmationTokens/ConfirmationTokenPaymentMethodDataPayByBankOptions.cs b/src/Stripe.net/Services/TestHelpers/ConfirmationTokens/ConfirmationTokenPaymentMethodDataPayByBankOptions.cs new file mode 100644 index 000000000..517cec3a8 --- /dev/null +++ b/src/Stripe.net/Services/TestHelpers/ConfirmationTokens/ConfirmationTokenPaymentMethodDataPayByBankOptions.cs @@ -0,0 +1,7 @@ +// File generated from our OpenAPI spec +namespace Stripe.TestHelpers +{ + public class ConfirmationTokenPaymentMethodDataPayByBankOptions : INestedOptions + { + } +} From 6fb2917a6b19d44df535430e2d6d4d154944f3fe Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Wed, 15 Jan 2025 21:04:46 +0000 Subject: [PATCH 09/17] Update generated code for v1449 --- OPENAPI_VERSION | 2 +- ...ntCompanyDirectorshipDeclarationOptions.cs | 43 +++++++++++++++++++ .../Accounts/AccountCompanyOptions.cs | 10 +++++ ...ntCompanyDirectorshipDeclarationOptions.cs | 43 +++++++++++++++++++ .../Tokens/TokenAccountCompanyOptions.cs | 10 +++++ 5 files changed, 107 insertions(+), 1 deletion(-) create mode 100644 src/Stripe.net/Services/Accounts/AccountCompanyDirectorshipDeclarationOptions.cs create mode 100644 src/Stripe.net/Services/Tokens/TokenAccountCompanyDirectorshipDeclarationOptions.cs diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 41237ba54..1b66f41fd 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1448 \ No newline at end of file +v1449 \ No newline at end of file diff --git a/src/Stripe.net/Services/Accounts/AccountCompanyDirectorshipDeclarationOptions.cs b/src/Stripe.net/Services/Accounts/AccountCompanyDirectorshipDeclarationOptions.cs new file mode 100644 index 000000000..51c2c31c9 --- /dev/null +++ b/src/Stripe.net/Services/Accounts/AccountCompanyDirectorshipDeclarationOptions.cs @@ -0,0 +1,43 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using System; + using Newtonsoft.Json; + using Stripe.Infrastructure; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountCompanyDirectorshipDeclarationOptions : INestedOptions + { + /// + /// The Unix timestamp marking when the directorship declaration attestation was made. + /// + [JsonProperty("date")] + [JsonConverter(typeof(UnixDateTimeConverter))] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("date")] + [STJS.JsonConverter(typeof(STJUnixDateTimeConverter))] +#endif + public DateTime? Date { get; set; } + + /// + /// The IP address from which the directorship declaration attestation was made. + /// + [JsonProperty("ip")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("ip")] +#endif + public string Ip { get; set; } + + /// + /// The user agent of the browser from which the directorship declaration attestation was + /// made. + /// + [JsonProperty("user_agent")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("user_agent")] +#endif + public string UserAgent { get; set; } + } +} diff --git a/src/Stripe.net/Services/Accounts/AccountCompanyOptions.cs b/src/Stripe.net/Services/Accounts/AccountCompanyOptions.cs index b21470928..9e330a587 100644 --- a/src/Stripe.net/Services/Accounts/AccountCompanyOptions.cs +++ b/src/Stripe.net/Services/Accounts/AccountCompanyOptions.cs @@ -49,6 +49,16 @@ public class AccountCompanyOptions : INestedOptions #endif public bool? DirectorsProvided { get; set; } + /// + /// This hash is used to attest that the directors information provided to Stripe is both + /// current and correct. + /// + [JsonProperty("directorship_declaration")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("directorship_declaration")] +#endif + public AccountCompanyDirectorshipDeclarationOptions DirectorshipDeclaration { get; set; } + /// /// Whether the company's executives have been provided. Set this Boolean to true /// after creating all the company's executives with + /// The Unix timestamp marking when the directorship declaration attestation was made. + /// + [JsonProperty("date")] + [JsonConverter(typeof(UnixDateTimeConverter))] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("date")] + [STJS.JsonConverter(typeof(STJUnixDateTimeConverter))] +#endif + public DateTime? Date { get; set; } + + /// + /// The IP address from which the directorship declaration attestation was made. + /// + [JsonProperty("ip")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("ip")] +#endif + public string Ip { get; set; } + + /// + /// The user agent of the browser from which the directorship declaration attestation was + /// made. + /// + [JsonProperty("user_agent")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("user_agent")] +#endif + public string UserAgent { get; set; } + } +} diff --git a/src/Stripe.net/Services/Tokens/TokenAccountCompanyOptions.cs b/src/Stripe.net/Services/Tokens/TokenAccountCompanyOptions.cs index 2949dd38a..aac9f0625 100644 --- a/src/Stripe.net/Services/Tokens/TokenAccountCompanyOptions.cs +++ b/src/Stripe.net/Services/Tokens/TokenAccountCompanyOptions.cs @@ -49,6 +49,16 @@ public class TokenAccountCompanyOptions : INestedOptions #endif public bool? DirectorsProvided { get; set; } + /// + /// This hash is used to attest that the directors information provided to Stripe is both + /// current and correct. + /// + [JsonProperty("directorship_declaration")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("directorship_declaration")] +#endif + public TokenAccountCompanyDirectorshipDeclarationOptions DirectorshipDeclaration { get; set; } + /// /// Whether the company's executives have been provided. Set this Boolean to true /// after creating all the company's executives with Date: Wed, 15 Jan 2025 22:26:43 +0000 Subject: [PATCH 10/17] Update generated code for v1450 --- OPENAPI_VERSION | 2 +- .../Accounts/AccountDocumentsOptions.cs | 9 ++++++++ ...oofOfUltimateBeneficialOwnershipOptions.cs | 23 +++++++++++++++++++ 3 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 src/Stripe.net/Services/Accounts/AccountDocumentsProofOfUltimateBeneficialOwnershipOptions.cs diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 1b66f41fd..fc039b0b5 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1449 \ No newline at end of file +v1450 \ No newline at end of file diff --git a/src/Stripe.net/Services/Accounts/AccountDocumentsOptions.cs b/src/Stripe.net/Services/Accounts/AccountDocumentsOptions.cs index 495017bf8..016acde5c 100644 --- a/src/Stripe.net/Services/Accounts/AccountDocumentsOptions.cs +++ b/src/Stripe.net/Services/Accounts/AccountDocumentsOptions.cs @@ -77,5 +77,14 @@ public class AccountDocumentsOptions : INestedOptions [STJS.JsonPropertyName("proof_of_registration")] #endif public AccountDocumentsProofOfRegistrationOptions ProofOfRegistration { get; set; } + + /// + /// One or more documents that demonstrate proof of ultimate beneficial ownership. + /// + [JsonProperty("proof_of_ultimate_beneficial_ownership")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("proof_of_ultimate_beneficial_ownership")] +#endif + public AccountDocumentsProofOfUltimateBeneficialOwnershipOptions ProofOfUltimateBeneficialOwnership { get; set; } } } diff --git a/src/Stripe.net/Services/Accounts/AccountDocumentsProofOfUltimateBeneficialOwnershipOptions.cs b/src/Stripe.net/Services/Accounts/AccountDocumentsProofOfUltimateBeneficialOwnershipOptions.cs new file mode 100644 index 000000000..a64be73b4 --- /dev/null +++ b/src/Stripe.net/Services/Accounts/AccountDocumentsProofOfUltimateBeneficialOwnershipOptions.cs @@ -0,0 +1,23 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using System.Collections.Generic; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountDocumentsProofOfUltimateBeneficialOwnershipOptions : INestedOptions + { + /// + /// One or more document ids returned by a file upload with a purpose + /// value of account_requirement. + /// + [JsonProperty("files")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("files")] +#endif + public List Files { get; set; } + } +} From b745c3ab035ef0e9dcb9790f924c6318cb6aaff7 Mon Sep 17 00:00:00 2001 From: jar-stripe Date: Thu, 16 Jan 2025 10:01:08 -0800 Subject: [PATCH 11/17] pinned ubuntu version and added TODO (#3047) --- .github/workflows/ci.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8918de61b..4e92eca6c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -21,7 +21,8 @@ jobs: build: name: Build and test - runs-on: ubuntu-latest + # TODO: this step is not compatible with ubuntu 24 LTS, so we pin the version here instead of using ubuntu-latest + runs-on: ubuntu-22.04 steps: - uses: extractions/setup-just@v2 From a9c875fbfe6df7a2146f670ac409e013a9d65cba Mon Sep 17 00:00:00 2001 From: jar-stripe Date: Thu, 16 Jan 2025 10:11:36 -0800 Subject: [PATCH 12/17] Added CONTRIBUTING.md file (#3045) --- CONTRIBUTING.md | 25 +++++++++++++++++++++++++ README.md | 2 ++ 2 files changed, 27 insertions(+) create mode 100644 CONTRIBUTING.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 000000000..a981948cb --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,25 @@ + +# Contributing + +We welcome bug reports, feature requests, and code contributions in a pull request. + +For most pull requests, we request that you identify or create an associated issue that has the necessary context. We use these issues to reach agreement on an approach and save the PR author from having to redo work. Fixing typos or documentation issues likely do not need an issue; for any issue that introduces substantial code changes, changes the public interface, or if you aren't sure, please find or [create an issue](https://www.github.com/stripe/stripe-dotnet/issues/new/choose). + +## Contributor License Agreement + +All contributors must sign the Contributor License Agreement (CLA) before we can accept their contribution. If you have not yet signed the agreement, you will be given an option to do so when you open a pull request. You can then sign by clicking on the badge in the comment from @CLAassistant. + +## Generated code + +This project has a combination of manually maintained code and code generated from our private code generator. If your contribution involves changes to generated code, please call this out in the issue or pull request as we will likely need to make a change to our code generator before accepting the contribution. + +To identify files with purely generated code, look for the comment `File generated from our OpenAPI spec.` at the start of the file. Generated blocks of code within hand-written files will be between comments that say `The beginning of the section generated from our OpenAPI spec` and `The end of the section generated from our OpenAPI spec`. + +## Compatibility with supported language and runtime versions + +This project supports [many different langauge and runtime versions](README.md#requirements) and we are unable to accept any contribution that does not work on _all_ supported versions. If, after discussing the approach in the associated issue, your change must use an API / feature that isn't available in all supported versions, please call this out explicitly in the issue or pull request so we can help figure out the best way forward. + +## Set up your dev environment + +Please refer to this project's [README.md](README.md#development) for instructions on how to set up your development environment. + diff --git a/README.md b/README.md index 31eb1aaf2..cdfc5f8b5 100644 --- a/README.md +++ b/README.md @@ -308,6 +308,8 @@ New features and bug fixes are released on the latest major version of the Strip ## Development +[Contribution guidelines for this project](CONTRIBUTING.md) + .NET 8 is required to build and test Stripe.net SDK, you can install it from [get.dot.net](https://get.dot.net/). The test suite depends on [stripe-mock][stripe-mock], so make sure to fetch From b263a39180e67868e4fb5d92f0c7c6e921b68428 Mon Sep 17 00:00:00 2001 From: David Brownman <109395161+xavdid-stripe@users.noreply.github.com> Date: Thu, 16 Jan 2025 11:34:16 -0800 Subject: [PATCH 13/17] update justfile import (#3046) --- justfile | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/justfile b/justfile index 87c26cf39..50a0dcbfe 100644 --- a/justfile +++ b/justfile @@ -1,6 +1,6 @@ set quiet -import? '../sdk-codegen/justfile' +import? '../sdk-codegen/utils.just' _default: just --list --unsorted @@ -22,10 +22,6 @@ format *args: # This sets TargetFramework because of a race condition in dotnet format when it tries to format to multiple targets at a time, which could lead to code with compiler errors after it completes TargetFramework=net5.0 dotnet format src/Stripe.net/Stripe.net.csproj --severity warn {{args}} -# for backwards compatibility; ideally removed later -[private] -alias codegen-format := format - # verify, but don't modify, the project's formatting format-check: (format "--verify-no-changes") From 61a7c0ef742f390a1fe41501a0cde634931cb57f Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Fri, 17 Jan 2025 14:48:35 +0000 Subject: [PATCH 14/17] Update generated code for v1452 --- OPENAPI_VERSION | 2 +- .../FinancialConnections/Transactions/TransactionListOptions.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index fc039b0b5..b8e108d5a 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1450 \ No newline at end of file +v1452 \ No newline at end of file diff --git a/src/Stripe.net/Services/FinancialConnections/Transactions/TransactionListOptions.cs b/src/Stripe.net/Services/FinancialConnections/Transactions/TransactionListOptions.cs index b97eb0c21..f335cf09e 100644 --- a/src/Stripe.net/Services/FinancialConnections/Transactions/TransactionListOptions.cs +++ b/src/Stripe.net/Services/FinancialConnections/Transactions/TransactionListOptions.cs @@ -11,7 +11,7 @@ namespace Stripe.FinancialConnections public class TransactionListOptions : ListOptions { /// - /// The ID of the Stripe account whose transactions will be retrieved. + /// The ID of the Financial Connections Account whose transactions will be retrieved. /// [JsonProperty("account")] #if NET6_0_OR_GREATER From 18a1f4d9cdc35a54da7a1f357ca804898fb9beea Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Fri, 17 Jan 2025 18:18:48 +0000 Subject: [PATCH 15/17] Update generated code for v1453 --- OPENAPI_VERSION | 2 +- .../ConfigurationFeaturesSubscriptionCancel.cs | 2 +- .../ConfigurationFeaturesSubscriptionCancelOptions.cs | 7 ++++--- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index b8e108d5a..59bdaaed2 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1452 \ No newline at end of file +v1453 \ No newline at end of file diff --git a/src/Stripe.net/Entities/BillingPortal/Configurations/ConfigurationFeaturesSubscriptionCancel.cs b/src/Stripe.net/Entities/BillingPortal/Configurations/ConfigurationFeaturesSubscriptionCancel.cs index 29c7c347b..4bf9fd4a0 100644 --- a/src/Stripe.net/Entities/BillingPortal/Configurations/ConfigurationFeaturesSubscriptionCancel.cs +++ b/src/Stripe.net/Entities/BillingPortal/Configurations/ConfigurationFeaturesSubscriptionCancel.cs @@ -36,7 +36,7 @@ public class ConfigurationFeaturesSubscriptionCancel : StripeEntity /// Whether to create prorations when canceling subscriptions. Possible values are /// none and create_prorations. - /// One of: create_prorations, or none. + /// One of: always_invoice, create_prorations, or none. /// [JsonProperty("proration_behavior")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/BillingPortal/Configurations/ConfigurationFeaturesSubscriptionCancelOptions.cs b/src/Stripe.net/Services/BillingPortal/Configurations/ConfigurationFeaturesSubscriptionCancelOptions.cs index df02202a8..1be46de23 100644 --- a/src/Stripe.net/Services/BillingPortal/Configurations/ConfigurationFeaturesSubscriptionCancelOptions.cs +++ b/src/Stripe.net/Services/BillingPortal/Configurations/ConfigurationFeaturesSubscriptionCancelOptions.cs @@ -40,9 +40,10 @@ public class ConfigurationFeaturesSubscriptionCancelOptions : INestedOptions /// /// Whether to create prorations when canceling subscriptions. Possible values are /// none and create_prorations, which is only compatible with - /// mode=immediately. No prorations are generated when canceling a subscription at - /// the end of its natural billing period. - /// One of: create_prorations, or none. + /// mode=immediately. Passing always_invoice will result in an error. No + /// prorations are generated when canceling a subscription at the end of its natural billing + /// period. + /// One of: always_invoice, create_prorations, or none. /// [JsonProperty("proration_behavior")] #if NET6_0_OR_GREATER From 74c57c0acc973c2434cabf9807ad197dcc5ec239 Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Fri, 17 Jan 2025 22:32:24 +0000 Subject: [PATCH 16/17] Update generated code for v1454 --- OPENAPI_VERSION | 2 +- src/Stripe.net/Constants/ApiVersion.cs | 2 +- .../Services/WebhookEndpoints/WebhookEndpointCreateOptions.cs | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 59bdaaed2..4624c15fb 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1453 \ No newline at end of file +v1454 \ No newline at end of file diff --git a/src/Stripe.net/Constants/ApiVersion.cs b/src/Stripe.net/Constants/ApiVersion.cs index 6c56685a1..93384759f 100644 --- a/src/Stripe.net/Constants/ApiVersion.cs +++ b/src/Stripe.net/Constants/ApiVersion.cs @@ -3,6 +3,6 @@ namespace Stripe { internal class ApiVersion { - public const string Current = "2024-12-18.acacia"; + public const string Current = "2025-01-27.acacia"; } } \ No newline at end of file diff --git a/src/Stripe.net/Services/WebhookEndpoints/WebhookEndpointCreateOptions.cs b/src/Stripe.net/Services/WebhookEndpoints/WebhookEndpointCreateOptions.cs index babbedafb..fe5e4b17e 100644 --- a/src/Stripe.net/Services/WebhookEndpoints/WebhookEndpointCreateOptions.cs +++ b/src/Stripe.net/Services/WebhookEndpoints/WebhookEndpointCreateOptions.cs @@ -38,7 +38,8 @@ public class WebhookEndpointCreateOptions : BaseOptions, IHasMetadata /// 2019-11-05, 2019-12-03, 2020-03-02, 2020-08-27, /// 2022-08-01, 2022-11-15, 2023-08-16, 2023-10-16, /// 2024-04-10, 2024-06-20, 2024-09-30.acacia, - /// 2024-10-28.acacia, 2024-11-20.acacia, or 2024-12-18.acacia. + /// 2024-10-28.acacia, 2024-11-20.acacia, 2024-12-18.acacia, or + /// 2025-01-27.acacia. /// [JsonProperty("api_version")] #if NET6_0_OR_GREATER From fcefb5633a58d70136b94c7b511bca22bf9621cf Mon Sep 17 00:00:00 2001 From: Jesse Rosalia Date: Fri, 17 Jan 2025 16:14:40 -0800 Subject: [PATCH 17/17] added CONTRIBUTING.md --- CONTRIBUTING.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 CONTRIBUTING.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 000000000..a981948cb --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,25 @@ + +# Contributing + +We welcome bug reports, feature requests, and code contributions in a pull request. + +For most pull requests, we request that you identify or create an associated issue that has the necessary context. We use these issues to reach agreement on an approach and save the PR author from having to redo work. Fixing typos or documentation issues likely do not need an issue; for any issue that introduces substantial code changes, changes the public interface, or if you aren't sure, please find or [create an issue](https://www.github.com/stripe/stripe-dotnet/issues/new/choose). + +## Contributor License Agreement + +All contributors must sign the Contributor License Agreement (CLA) before we can accept their contribution. If you have not yet signed the agreement, you will be given an option to do so when you open a pull request. You can then sign by clicking on the badge in the comment from @CLAassistant. + +## Generated code + +This project has a combination of manually maintained code and code generated from our private code generator. If your contribution involves changes to generated code, please call this out in the issue or pull request as we will likely need to make a change to our code generator before accepting the contribution. + +To identify files with purely generated code, look for the comment `File generated from our OpenAPI spec.` at the start of the file. Generated blocks of code within hand-written files will be between comments that say `The beginning of the section generated from our OpenAPI spec` and `The end of the section generated from our OpenAPI spec`. + +## Compatibility with supported language and runtime versions + +This project supports [many different langauge and runtime versions](README.md#requirements) and we are unable to accept any contribution that does not work on _all_ supported versions. If, after discussing the approach in the associated issue, your change must use an API / feature that isn't available in all supported versions, please call this out explicitly in the issue or pull request so we can help figure out the best way forward. + +## Set up your dev environment + +Please refer to this project's [README.md](README.md#development) for instructions on how to set up your development environment. +