diff --git a/API_VERSION b/API_VERSION index ab54b76b3e..8cbec87ebf 100644 --- a/API_VERSION +++ b/API_VERSION @@ -1 +1 @@ -2025-09-30.preview \ No newline at end of file +b7d9dec4da43fdbe727b3b4d8007a7099aa61beb \ No newline at end of file diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index f0bb0d526f..8a7edbe682 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v2028 \ No newline at end of file +v2100 \ No newline at end of file diff --git a/src/Stripe.net/Constants/FilePurpose.cs b/src/Stripe.net/Constants/FilePurpose.cs index b1d8112359..eb0738cffb 100644 --- a/src/Stripe.net/Constants/FilePurpose.cs +++ b/src/Stripe.net/Constants/FilePurpose.cs @@ -29,6 +29,8 @@ public static class FilePurpose public const string PciDocument = "pci_document"; + public const string PlatformTermsOfService = "platform_terms_of_service"; + public const string Selfie = "selfie"; public const string SigmaScheduledQuery = "sigma_scheduled_query"; diff --git a/src/Stripe.net/Entities/Accounts/AccountCompany.cs b/src/Stripe.net/Entities/Accounts/AccountCompany.cs index a8933b7d82..a7e851cfe1 100644 --- a/src/Stripe.net/Entities/Accounts/AccountCompany.cs +++ b/src/Stripe.net/Entities/Accounts/AccountCompany.cs @@ -177,6 +177,16 @@ public class AccountCompany : StripeEntity #endif public AccountCompanyRegistrationDate RegistrationDate { get; set; } + /// + /// This hash is used to attest that the representative is authorized to act as the + /// representative of their legal entity. + /// + [JsonProperty("representative_declaration")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("representative_declaration")] +#endif + public AccountCompanyRepresentativeDeclaration RepresentativeDeclaration { get; set; } + /// /// The category identifying the legal structure of the company or legal entity. Also /// available for accounts where + { + /// + /// The Unix timestamp marking when the representative 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 representative declaration attestation was made. + /// + [JsonProperty("ip")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("ip")] +#endif + public string Ip { get; set; } + + /// + /// The user-agent string from the browser where the representative 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/Entities/Accounts/AccountFutureRequirementsError.cs b/src/Stripe.net/Entities/Accounts/AccountFutureRequirementsError.cs index aba7a27142..6d725db48d 100644 --- a/src/Stripe.net/Entities/Accounts/AccountFutureRequirementsError.cs +++ b/src/Stripe.net/Entities/Accounts/AccountFutureRequirementsError.cs @@ -39,8 +39,8 @@ public class AccountFutureRequirementsError : StripeEntityinvalid_url_website_incomplete_terms_and_conditions, /// invalid_url_website_incomplete_under_construction, /// invalid_url_website_other, invalid_value_other, - /// unsupported_business_type, verification_directors_mismatch, - /// verification_document_address_mismatch, + /// unsupported_business_type, verification_data_not_found, + /// verification_directors_mismatch, verification_document_address_mismatch, /// verification_document_address_missing, verification_document_corrupt, /// verification_document_country_not_supported, /// verification_document_directors_mismatch, diff --git a/src/Stripe.net/Entities/Accounts/AccountRequirementsError.cs b/src/Stripe.net/Entities/Accounts/AccountRequirementsError.cs index bdb3516bef..88ada8001a 100644 --- a/src/Stripe.net/Entities/Accounts/AccountRequirementsError.cs +++ b/src/Stripe.net/Entities/Accounts/AccountRequirementsError.cs @@ -39,8 +39,8 @@ public class AccountRequirementsError : StripeEntity /// invalid_url_website_incomplete_terms_and_conditions, /// invalid_url_website_incomplete_under_construction, /// invalid_url_website_other, invalid_value_other, - /// unsupported_business_type, verification_directors_mismatch, - /// verification_document_address_mismatch, + /// unsupported_business_type, verification_data_not_found, + /// verification_directors_mismatch, verification_document_address_mismatch, /// verification_document_address_missing, verification_document_corrupt, /// verification_document_country_not_supported, /// verification_document_directors_mismatch, diff --git a/src/Stripe.net/Entities/BankAccounts/BankAccountFutureRequirementsError.cs b/src/Stripe.net/Entities/BankAccounts/BankAccountFutureRequirementsError.cs index 7715f48ca6..5259e27723 100644 --- a/src/Stripe.net/Entities/BankAccounts/BankAccountFutureRequirementsError.cs +++ b/src/Stripe.net/Entities/BankAccounts/BankAccountFutureRequirementsError.cs @@ -39,8 +39,8 @@ public class BankAccountFutureRequirementsError : StripeEntityinvalid_url_website_incomplete_terms_and_conditions, /// invalid_url_website_incomplete_under_construction, /// invalid_url_website_other, invalid_value_other, - /// unsupported_business_type, verification_directors_mismatch, - /// verification_document_address_mismatch, + /// unsupported_business_type, verification_data_not_found, + /// verification_directors_mismatch, verification_document_address_mismatch, /// verification_document_address_missing, verification_document_corrupt, /// verification_document_country_not_supported, /// verification_document_directors_mismatch, diff --git a/src/Stripe.net/Entities/BankAccounts/BankAccountRequirementsError.cs b/src/Stripe.net/Entities/BankAccounts/BankAccountRequirementsError.cs index 22b334096c..0cf1d828da 100644 --- a/src/Stripe.net/Entities/BankAccounts/BankAccountRequirementsError.cs +++ b/src/Stripe.net/Entities/BankAccounts/BankAccountRequirementsError.cs @@ -39,8 +39,8 @@ public class BankAccountRequirementsError : StripeEntityinvalid_url_website_incomplete_terms_and_conditions, /// invalid_url_website_incomplete_under_construction, /// invalid_url_website_other, invalid_value_other, - /// unsupported_business_type, verification_directors_mismatch, - /// verification_document_address_mismatch, + /// unsupported_business_type, verification_data_not_found, + /// verification_directors_mismatch, verification_document_address_mismatch, /// verification_document_address_missing, verification_document_corrupt, /// verification_document_country_not_supported, /// verification_document_directors_mismatch, diff --git a/src/Stripe.net/Entities/BillingPortal/Configurations/Configuration.cs b/src/Stripe.net/Entities/BillingPortal/Configurations/Configuration.cs index cf7986ff93..d295989483 100644 --- a/src/Stripe.net/Entities/BillingPortal/Configurations/Configuration.cs +++ b/src/Stripe.net/Entities/BillingPortal/Configurations/Configuration.cs @@ -10,7 +10,10 @@ namespace Stripe.BillingPortal #endif /// - /// A portal configuration describes the functionality and behavior of a portal session. + /// A portal configuration describes the functionality and behavior you embed in a portal + /// session. Related guide: Configure the customer + /// portal. /// #if NET6_0_OR_GREATER [STJS.JsonConverter(typeof(STJMemberSerializationOptIn))] diff --git a/src/Stripe.net/Entities/Capabilities/CapabilityFutureRequirementsError.cs b/src/Stripe.net/Entities/Capabilities/CapabilityFutureRequirementsError.cs index 03f8d94ad3..f0ca8f684f 100644 --- a/src/Stripe.net/Entities/Capabilities/CapabilityFutureRequirementsError.cs +++ b/src/Stripe.net/Entities/Capabilities/CapabilityFutureRequirementsError.cs @@ -39,8 +39,8 @@ public class CapabilityFutureRequirementsError : StripeEntityinvalid_url_website_incomplete_terms_and_conditions, /// invalid_url_website_incomplete_under_construction, /// invalid_url_website_other, invalid_value_other, - /// unsupported_business_type, verification_directors_mismatch, - /// verification_document_address_mismatch, + /// unsupported_business_type, verification_data_not_found, + /// verification_directors_mismatch, verification_document_address_mismatch, /// verification_document_address_missing, verification_document_corrupt, /// verification_document_country_not_supported, /// verification_document_directors_mismatch, diff --git a/src/Stripe.net/Entities/Charges/ChargePaymentMethodDetailsCrypto.cs b/src/Stripe.net/Entities/Charges/ChargePaymentMethodDetailsCrypto.cs index 48c7844bd5..731225fc48 100644 --- a/src/Stripe.net/Entities/Charges/ChargePaymentMethodDetailsCrypto.cs +++ b/src/Stripe.net/Entities/Charges/ChargePaymentMethodDetailsCrypto.cs @@ -19,7 +19,7 @@ public class ChargePaymentMethodDetailsCrypto : StripeEntity /// The blockchain network that the transaction was sent on. - /// One of: base, ethereum, or polygon. + /// One of: base, ethereum, polygon, or solana. /// [JsonProperty("network")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/Charges/ChargePaymentMethodDetailsRechnung.cs b/src/Stripe.net/Entities/Charges/ChargePaymentMethodDetailsRechnung.cs index 400a6ce90d..b92f252005 100644 --- a/src/Stripe.net/Entities/Charges/ChargePaymentMethodDetailsRechnung.cs +++ b/src/Stripe.net/Entities/Charges/ChargePaymentMethodDetailsRechnung.cs @@ -1,7 +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 ChargePaymentMethodDetailsRechnung : StripeEntity { + /// + /// Payment portal URL. + /// + [JsonProperty("payment_portal_url")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_portal_url")] +#endif + public string PaymentPortalUrl { get; set; } } } diff --git a/src/Stripe.net/Entities/Checkout/Sessions/SessionPaymentMethodOptions.cs b/src/Stripe.net/Entities/Checkout/Sessions/SessionPaymentMethodOptions.cs index b87ee4b31f..6a5edac236 100644 --- a/src/Stripe.net/Entities/Checkout/Sessions/SessionPaymentMethodOptions.cs +++ b/src/Stripe.net/Entities/Checkout/Sessions/SessionPaymentMethodOptions.cs @@ -248,6 +248,12 @@ public class SessionPaymentMethodOptions : StripeEntity + { + /// + /// Indicates that you intend to make future payments with this PaymentIntent's payment + /// method. + /// + /// If you provide a Customer with the PaymentIntent, you can use this parameter to attach the payment method to + /// the Customer after the PaymentIntent is confirmed and the customer completes any + /// required actions. If you don't provide a Customer, you can still attach the payment method to a + /// Customer after the transaction completes. + /// + /// If the payment method is card_present and isn't a digital wallet, Stripe creates + /// and attaches a generated_card + /// payment method representing the card to the Customer instead. + /// + /// When processing card payments, Stripe uses setup_future_usage to help you comply + /// with regional legislation and network rules, such as SCA. + /// + [JsonProperty("setup_future_usage")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("setup_future_usage")] +#endif + public string SetupFutureUsage { get; set; } + } +} diff --git a/src/Stripe.net/Entities/ConfirmationTokens/ConfirmationTokenPaymentMethodPreview.cs b/src/Stripe.net/Entities/ConfirmationTokens/ConfirmationTokenPaymentMethodPreview.cs index 2956253669..65de33815d 100644 --- a/src/Stripe.net/Entities/ConfirmationTokens/ConfirmationTokenPaymentMethodPreview.cs +++ b/src/Stripe.net/Entities/ConfirmationTokens/ConfirmationTokenPaymentMethodPreview.cs @@ -423,16 +423,16 @@ public Customer Customer /// One of: acss_debit, affirm, afterpay_clearpay, alipay, /// alma, amazon_pay, au_becs_debit, bacs_debit, /// bancontact, billie, blik, boleto, card, - /// card_present, cashapp, crypto, customer_balance, eps, - /// fpx, giropay, gopay, grabpay, id_bank_transfer, - /// ideal, interac_present, kakao_pay, klarna, konbini, - /// kr_card, link, mb_way, mobilepay, multibanco, - /// naver_pay, nz_bank_account, oxxo, p24, pay_by_bank, - /// payco, paynow, paypal, paypay, payto, pix, - /// promptpay, qris, rechnung, revolut_pay, samsung_pay, - /// satispay, sepa_debit, shopeepay, sofort, - /// stripe_balance, swish, twint, us_bank_account, - /// wechat_pay, or zip. + /// card_present, cashapp, crypto, custom, + /// customer_balance, eps, fpx, giropay, gopay, + /// grabpay, id_bank_transfer, ideal, interac_present, + /// kakao_pay, klarna, konbini, kr_card, link, + /// mb_way, mobilepay, multibanco, naver_pay, + /// nz_bank_account, oxxo, p24, pay_by_bank, payco, + /// paynow, paypal, paypay, payto, pix, promptpay, + /// qris, rechnung, revolut_pay, samsung_pay, satispay, + /// sepa_debit, shopeepay, sofort, stripe_balance, swish, + /// twint, us_bank_account, wechat_pay, or zip. /// [JsonProperty("type")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/CreditNotes/CreditNoteRefund.cs b/src/Stripe.net/Entities/CreditNotes/CreditNoteRefund.cs index 1c85661012..e1da026531 100644 --- a/src/Stripe.net/Entities/CreditNotes/CreditNoteRefund.cs +++ b/src/Stripe.net/Entities/CreditNotes/CreditNoteRefund.cs @@ -21,6 +21,15 @@ public class CreditNoteRefund : StripeEntity #endif public long AmountRefunded { get; set; } + /// + /// The PaymentRecord refund details associated with this credit note refund. + /// + [JsonProperty("payment_record_refund")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_record_refund")] +#endif + public CreditNoteRefundPaymentRecordRefund PaymentRecordRefund { get; set; } + #region Expandable Refund /// @@ -61,5 +70,15 @@ public Refund Refund #endif internal ExpandableField InternalRefund { get; set; } #endregion + + /// + /// Type of the refund, one of refund or payment_record_refund. + /// One of: payment_record_refund, or refund. + /// + [JsonProperty("type")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("type")] +#endif + public string Type { get; set; } } } diff --git a/src/Stripe.net/Entities/CreditNotes/CreditNoteRefundPaymentRecordRefund.cs b/src/Stripe.net/Entities/CreditNotes/CreditNoteRefundPaymentRecordRefund.cs new file mode 100644 index 0000000000..0e677c2e0e --- /dev/null +++ b/src/Stripe.net/Entities/CreditNotes/CreditNoteRefundPaymentRecordRefund.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 CreditNoteRefundPaymentRecordRefund : StripeEntity + { + /// + /// ID of the payment record. + /// + [JsonProperty("payment_record")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_record")] +#endif + public string PaymentRecord { get; set; } + + /// + /// ID of the refund group. + /// + [JsonProperty("refund_group")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("refund_group")] +#endif + public string RefundGroup { get; set; } + } +} diff --git a/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponents.cs b/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponents.cs index 6192c24efb..22925dc910 100644 --- a/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponents.cs +++ b/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponents.cs @@ -17,6 +17,25 @@ public class CustomerSessionComponents : StripeEntity #endif public CustomerSessionComponentsBuyButton BuyButton { get; set; } + /// + /// This hash contains whether the customer sheet is enabled and the features it supports. + /// + [JsonProperty("customer_sheet")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("customer_sheet")] +#endif + public CustomerSessionComponentsCustomerSheet CustomerSheet { get; set; } + + /// + /// This hash contains whether the mobile payment element is enabled and the features it + /// supports. + /// + [JsonProperty("mobile_payment_element")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("mobile_payment_element")] +#endif + public CustomerSessionComponentsMobilePaymentElement MobilePaymentElement { get; set; } + /// /// This hash contains whether the Payment Element is enabled and the features it supports. /// @@ -34,5 +53,14 @@ public class CustomerSessionComponents : StripeEntity [STJS.JsonPropertyName("pricing_table")] #endif public CustomerSessionComponentsPricingTable PricingTable { get; set; } + + /// + /// This hash contains whether the Tax ID Element is enabled and the features it supports. + /// + [JsonProperty("tax_id_element")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("tax_id_element")] +#endif + public CustomerSessionComponentsTaxIdElement TaxIdElement { get; set; } } } diff --git a/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsCustomerSheet.cs b/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsCustomerSheet.cs new file mode 100644 index 0000000000..8d09e933cc --- /dev/null +++ b/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsCustomerSheet.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 CustomerSessionComponentsCustomerSheet : StripeEntity + { + /// + /// Whether the customer sheet is enabled. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool Enabled { get; set; } + + /// + /// This hash defines whether the customer sheet supports certain features. + /// + [JsonProperty("features")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("features")] +#endif + public CustomerSessionComponentsCustomerSheetFeatures Features { get; set; } + } +} diff --git a/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsCustomerSheetFeatures.cs b/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsCustomerSheetFeatures.cs new file mode 100644 index 0000000000..3e4eaae646 --- /dev/null +++ b/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsCustomerSheetFeatures.cs @@ -0,0 +1,46 @@ +// 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 CustomerSessionComponentsCustomerSheetFeatures : StripeEntity + { + /// + /// A list of allow_redisplay + /// values that controls which saved payment methods the customer sheet displays by + /// filtering to only show payment methods with an allow_redisplay value that is + /// present in this list. + /// + /// If not specified, defaults to ["always"]. In order to display all saved payment methods, + /// specify ["always", "limited", "unspecified"]. + /// One of: always, limited, or unspecified. + /// + [JsonProperty("payment_method_allow_redisplay_filters")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_allow_redisplay_filters")] +#endif + public List PaymentMethodAllowRedisplayFilters { get; set; } + + /// + /// Controls whether the customer sheet displays the option to remove a saved payment + /// method.". + /// + /// Allowing buyers to remove their saved payment methods impacts subscriptions that depend + /// on that payment method. Removing the payment method detaches the customer + /// object from that PaymentMethod. + /// One of: disabled, or enabled. + /// + [JsonProperty("payment_method_remove")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_remove")] +#endif + public string PaymentMethodRemove { get; set; } + } +} diff --git a/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsMobilePaymentElement.cs b/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsMobilePaymentElement.cs new file mode 100644 index 0000000000..d53f6455bb --- /dev/null +++ b/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsMobilePaymentElement.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 CustomerSessionComponentsMobilePaymentElement : StripeEntity + { + /// + /// Whether the mobile payment element is enabled. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool Enabled { get; set; } + + /// + /// This hash defines whether the mobile payment element supports certain features. + /// + [JsonProperty("features")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("features")] +#endif + public CustomerSessionComponentsMobilePaymentElementFeatures Features { get; set; } + } +} diff --git a/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsMobilePaymentElementFeatures.cs b/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsMobilePaymentElementFeatures.cs new file mode 100644 index 0000000000..d30bbd9d9e --- /dev/null +++ b/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsMobilePaymentElementFeatures.cs @@ -0,0 +1,88 @@ +// 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 CustomerSessionComponentsMobilePaymentElementFeatures : StripeEntity + { + /// + /// A list of allow_redisplay + /// values that controls which saved payment methods the mobile payment element displays by + /// filtering to only show payment methods with an allow_redisplay value that is + /// present in this list. + /// + /// If not specified, defaults to ["always"]. In order to display all saved payment methods, + /// specify ["always", "limited", "unspecified"]. + /// One of: always, limited, or unspecified. + /// + [JsonProperty("payment_method_allow_redisplay_filters")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_allow_redisplay_filters")] +#endif + public List PaymentMethodAllowRedisplayFilters { get; set; } + + /// + /// Controls whether or not the mobile payment element shows saved payment methods. + /// One of: disabled, or enabled. + /// + [JsonProperty("payment_method_redisplay")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_redisplay")] +#endif + public string PaymentMethodRedisplay { get; set; } + + /// + /// Controls whether the mobile payment element displays the option to remove a saved + /// payment method.". + /// + /// Allowing buyers to remove their saved payment methods impacts subscriptions that depend + /// on that payment method. Removing the payment method detaches the customer + /// object from that PaymentMethod. + /// One of: disabled, or enabled. + /// + [JsonProperty("payment_method_remove")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_remove")] +#endif + public string PaymentMethodRemove { get; set; } + + /// + /// Controls whether the mobile payment element displays a checkbox offering to save a new + /// payment method. + /// + /// If a customer checks the box, the allow_redisplay + /// value on the PaymentMethod is set to 'always' at confirmation time. For + /// PaymentIntents, the setup_future_usage + /// value is also set to the value defined in payment_method_save_usage. + /// One of: disabled, or enabled. + /// + [JsonProperty("payment_method_save")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_save")] +#endif + public string PaymentMethodSave { get; set; } + + /// + /// Allows overriding the value of allow_override when saving a new payment method when + /// payment_method_save is set to disabled. Use values: "always", "limited", or + /// "unspecified". + /// + /// If not specified, defaults to nil (no override value). + /// One of: always, limited, or unspecified. + /// + [JsonProperty("payment_method_save_allow_redisplay_override")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_save_allow_redisplay_override")] +#endif + public string PaymentMethodSaveAllowRedisplayOverride { get; set; } + } +} diff --git a/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsTaxIdElement.cs b/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsTaxIdElement.cs new file mode 100644 index 0000000000..5604ee3b93 --- /dev/null +++ b/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsTaxIdElement.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 CustomerSessionComponentsTaxIdElement : StripeEntity + { + /// + /// Whether the Tax ID Element is enabled. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool Enabled { get; set; } + + /// + /// This hash defines whether the Tax ID Element supports certain features. + /// + [JsonProperty("features")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("features")] +#endif + public CustomerSessionComponentsTaxIdElementFeatures Features { get; set; } + } +} diff --git a/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsTaxIdElementFeatures.cs b/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsTaxIdElementFeatures.cs new file mode 100644 index 0000000000..92258ef7c6 --- /dev/null +++ b/src/Stripe.net/Entities/CustomerSessions/CustomerSessionComponentsTaxIdElementFeatures.cs @@ -0,0 +1,40 @@ +// 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 CustomerSessionComponentsTaxIdElementFeatures : StripeEntity + { + /// + /// Controls whether the Tax ID Element displays saved tax IDs for the customer. This + /// parameter defaults to disabled. + /// + /// When enabled, the Tax ID Element will show existing tax IDs associated with the + /// customer, allowing them to select from previously saved tax identification numbers. + /// One of: disabled, or enabled. + /// + [JsonProperty("tax_id_redisplay")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("tax_id_redisplay")] +#endif + public string TaxIdRedisplay { get; set; } + + /// + /// Controls whether the Tax ID Element allows merchants to save new tax IDs for their + /// customer. This parameter defaults to disabled. + /// + /// When enabled, customers can enter and save new tax identification numbers during the + /// payment flow, which will be stored securely and associated with their customer object + /// for future use. + /// One of: disabled, or enabled. + /// + [JsonProperty("tax_id_save")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("tax_id_save")] +#endif + public string TaxIdSave { get; set; } + } +} diff --git a/src/Stripe.net/Entities/Customers/CustomerTax.cs b/src/Stripe.net/Entities/Customers/CustomerTax.cs index df24d7c5b0..b735cbbec5 100644 --- a/src/Stripe.net/Entities/Customers/CustomerTax.cs +++ b/src/Stripe.net/Entities/Customers/CustomerTax.cs @@ -37,5 +37,17 @@ public class CustomerTax : StripeEntity [STJS.JsonPropertyName("location")] #endif public CustomerTaxLocation Location { get; set; } + + /// + /// The tax calculation provider used for location resolution. Defaults to stripe + /// when not using a third-party + /// provider. + /// One of: anrok, avalara, sphere, or stripe. + /// + [JsonProperty("provider")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("provider")] +#endif + public string Provider { get; set; } } } diff --git a/src/Stripe.net/Entities/Files/File.cs b/src/Stripe.net/Entities/Files/File.cs index 2e4d276c08..19f228fa55 100644 --- a/src/Stripe.net/Entities/Files/File.cs +++ b/src/Stripe.net/Entities/Files/File.cs @@ -86,9 +86,9 @@ public class File : StripeEntity, IHasId, IHasObject /// dispute_evidence, document_provider_identity_document, /// finance_report_run, financial_account_statement, identity_document, /// identity_document_downloadable, issuing_regulatory_reporting, - /// pci_document, selfie, sigma_scheduled_query, - /// tax_document_user_upload, terminal_android_apk, or - /// terminal_reader_splashscreen. + /// pci_document, platform_terms_of_service, selfie, + /// sigma_scheduled_query, tax_document_user_upload, + /// terminal_android_apk, or terminal_reader_splashscreen. /// [JsonProperty("purpose")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/PaymentAttemptRecords/PaymentAttemptRecordPaymentMethodDetailsCrypto.cs b/src/Stripe.net/Entities/PaymentAttemptRecords/PaymentAttemptRecordPaymentMethodDetailsCrypto.cs index 3d164510d7..f9487ba03d 100644 --- a/src/Stripe.net/Entities/PaymentAttemptRecords/PaymentAttemptRecordPaymentMethodDetailsCrypto.cs +++ b/src/Stripe.net/Entities/PaymentAttemptRecords/PaymentAttemptRecordPaymentMethodDetailsCrypto.cs @@ -19,7 +19,7 @@ public class PaymentAttemptRecordPaymentMethodDetailsCrypto : StripeEntity /// The blockchain network that the transaction was sent on. - /// One of: base, ethereum, or polygon. + /// One of: base, ethereum, polygon, or solana. /// [JsonProperty("network")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/PaymentAttemptRecords/PaymentAttemptRecordPaymentMethodDetailsRechnung.cs b/src/Stripe.net/Entities/PaymentAttemptRecords/PaymentAttemptRecordPaymentMethodDetailsRechnung.cs index 6e7424e126..999e6ff217 100644 --- a/src/Stripe.net/Entities/PaymentAttemptRecords/PaymentAttemptRecordPaymentMethodDetailsRechnung.cs +++ b/src/Stripe.net/Entities/PaymentAttemptRecords/PaymentAttemptRecordPaymentMethodDetailsRechnung.cs @@ -1,7 +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 PaymentAttemptRecordPaymentMethodDetailsRechnung : StripeEntity { + /// + /// Payment portal URL. + /// + [JsonProperty("payment_portal_url")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_portal_url")] +#endif + public string PaymentPortalUrl { get; set; } } } diff --git a/src/Stripe.net/Entities/PaymentIntentAmountDetailsLineItems/PaymentIntentAmountDetailsLineItemPaymentMethodOptionsKlarna.cs b/src/Stripe.net/Entities/PaymentIntentAmountDetailsLineItems/PaymentIntentAmountDetailsLineItemPaymentMethodOptionsKlarna.cs index 68bddc7a0a..d9d9bea92c 100644 --- a/src/Stripe.net/Entities/PaymentIntentAmountDetailsLineItems/PaymentIntentAmountDetailsLineItemPaymentMethodOptionsKlarna.cs +++ b/src/Stripe.net/Entities/PaymentIntentAmountDetailsLineItems/PaymentIntentAmountDetailsLineItemPaymentMethodOptionsKlarna.cs @@ -19,5 +19,17 @@ public class PaymentIntentAmountDetailsLineItemPaymentMethodOptionsKlarna : Stri [STJS.JsonPropertyName("product_url")] #endif public string ProductUrl { get; set; } + + [JsonProperty("reference")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("reference")] +#endif + public string Reference { get; set; } + + [JsonProperty("subscription_reference")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("subscription_reference")] +#endif + public string SubscriptionReference { get; set; } } } diff --git a/src/Stripe.net/Entities/PaymentLinks/PaymentLink.cs b/src/Stripe.net/Entities/PaymentLinks/PaymentLink.cs index 5099b90c36..19f83639aa 100644 --- a/src/Stripe.net/Entities/PaymentLinks/PaymentLink.cs +++ b/src/Stripe.net/Entities/PaymentLinks/PaymentLink.cs @@ -240,6 +240,12 @@ public Application Application #endif public Dictionary Metadata { get; set; } + [JsonProperty("name_collection")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("name_collection")] +#endif + public PaymentLinkNameCollection NameCollection { get; set; } + #region Expandable OnBehalfOf /// diff --git a/src/Stripe.net/Entities/PaymentLinks/PaymentLinkNameCollection.cs b/src/Stripe.net/Entities/PaymentLinks/PaymentLinkNameCollection.cs new file mode 100644 index 0000000000..a14f7ecc8e --- /dev/null +++ b/src/Stripe.net/Entities/PaymentLinks/PaymentLinkNameCollection.cs @@ -0,0 +1,23 @@ +// 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 PaymentLinkNameCollection : StripeEntity + { + [JsonProperty("business")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("business")] +#endif + public PaymentLinkNameCollectionBusiness Business { get; set; } + + [JsonProperty("individual")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("individual")] +#endif + public PaymentLinkNameCollectionIndividual Individual { get; set; } + } +} diff --git a/src/Stripe.net/Entities/PaymentLinks/PaymentLinkNameCollectionBusiness.cs b/src/Stripe.net/Entities/PaymentLinks/PaymentLinkNameCollectionBusiness.cs new file mode 100644 index 0000000000..4d69b826f2 --- /dev/null +++ b/src/Stripe.net/Entities/PaymentLinks/PaymentLinkNameCollectionBusiness.cs @@ -0,0 +1,30 @@ +// 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 PaymentLinkNameCollectionBusiness : StripeEntity + { + /// + /// Indicates whether business name collection is enabled for the payment link. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool Enabled { get; set; } + + /// + /// Whether the customer is required to complete the field before checking out. Defaults to + /// false. + /// + [JsonProperty("optional")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("optional")] +#endif + public bool Optional { get; set; } + } +} diff --git a/src/Stripe.net/Entities/PaymentLinks/PaymentLinkNameCollectionIndividual.cs b/src/Stripe.net/Entities/PaymentLinks/PaymentLinkNameCollectionIndividual.cs new file mode 100644 index 0000000000..8c6f95ebca --- /dev/null +++ b/src/Stripe.net/Entities/PaymentLinks/PaymentLinkNameCollectionIndividual.cs @@ -0,0 +1,30 @@ +// 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 PaymentLinkNameCollectionIndividual : StripeEntity + { + /// + /// Indicates whether individual name collection is enabled for the payment link. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool Enabled { get; set; } + + /// + /// Whether the customer is required to complete the field before checking out. Defaults to + /// false. + /// + [JsonProperty("optional")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("optional")] +#endif + public bool Optional { get; set; } + } +} diff --git a/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfiguration.cs b/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfiguration.cs index b56688f956..a93d214ee2 100644 --- a/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfiguration.cs +++ b/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfiguration.cs @@ -170,6 +170,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 PaymentMethodConfigurationCryptoDisplayPreference DisplayPreference { get; set; } + } +} diff --git a/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfigurationCryptoDisplayPreference.cs b/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfigurationCryptoDisplayPreference.cs new file mode 100644 index 0000000000..9ffe4f3e5f --- /dev/null +++ b/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfigurationCryptoDisplayPreference.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 PaymentMethodConfigurationCryptoDisplayPreference : 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/PaymentMethodConfigurations/PaymentMethodConfigurationMbWay.cs b/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfigurationMbWay.cs new file mode 100644 index 0000000000..84959fbff3 --- /dev/null +++ b/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfigurationMbWay.cs @@ -0,0 +1,27 @@ +// 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 PaymentMethodConfigurationMbWay : 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 PaymentMethodConfigurationMbWayDisplayPreference DisplayPreference { get; set; } + } +} diff --git a/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfigurationMbWayDisplayPreference.cs b/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfigurationMbWayDisplayPreference.cs new file mode 100644 index 0000000000..825e6fe18b --- /dev/null +++ b/src/Stripe.net/Entities/PaymentMethodConfigurations/PaymentMethodConfigurationMbWayDisplayPreference.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 PaymentMethodConfigurationMbWayDisplayPreference : 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 f3b9e67e26..36cd39926e 100644 --- a/src/Stripe.net/Entities/PaymentMethods/PaymentMethod.cs +++ b/src/Stripe.net/Entities/PaymentMethods/PaymentMethod.cs @@ -168,6 +168,12 @@ public class PaymentMethod : StripeEntity, IHasId, IHasMetadata, #endif public PaymentMethodCrypto Crypto { get; set; } + [JsonProperty("custom")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("custom")] +#endif + public PaymentMethodCustom Custom { get; set; } + #region Expandable Customer /// @@ -506,16 +512,16 @@ public Customer Customer /// One of: acss_debit, affirm, afterpay_clearpay, alipay, /// alma, amazon_pay, au_becs_debit, bacs_debit, /// bancontact, billie, blik, boleto, card, - /// card_present, cashapp, crypto, customer_balance, eps, - /// fpx, giropay, gopay, grabpay, id_bank_transfer, - /// ideal, interac_present, kakao_pay, klarna, konbini, - /// kr_card, link, mb_way, mobilepay, multibanco, - /// naver_pay, nz_bank_account, oxxo, p24, pay_by_bank, - /// payco, paynow, paypal, paypay, payto, pix, - /// promptpay, qris, rechnung, revolut_pay, samsung_pay, - /// satispay, sepa_debit, shopeepay, sofort, - /// stripe_balance, swish, twint, us_bank_account, - /// wechat_pay, or zip. + /// card_present, cashapp, crypto, custom, + /// customer_balance, eps, fpx, giropay, gopay, + /// grabpay, id_bank_transfer, ideal, interac_present, + /// kakao_pay, klarna, konbini, kr_card, link, + /// mb_way, mobilepay, multibanco, naver_pay, + /// nz_bank_account, oxxo, p24, pay_by_bank, payco, + /// paynow, paypal, paypay, payto, pix, promptpay, + /// qris, rechnung, revolut_pay, samsung_pay, satispay, + /// sepa_debit, shopeepay, sofort, stripe_balance, swish, + /// twint, us_bank_account, wechat_pay, or zip. /// [JsonProperty("type")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/PaymentMethods/PaymentMethodCustom.cs b/src/Stripe.net/Entities/PaymentMethods/PaymentMethodCustom.cs new file mode 100644 index 0000000000..72d48d1cd5 --- /dev/null +++ b/src/Stripe.net/Entities/PaymentMethods/PaymentMethodCustom.cs @@ -0,0 +1,38 @@ +// 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 PaymentMethodCustom : StripeEntity + { + /// + /// Display name of the Dashboard-only CustomPaymentMethodType. + /// + [JsonProperty("display_name")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("display_name")] +#endif + public string DisplayName { get; set; } + + /// + /// Contains information about the Dashboard-only CustomPaymentMethodType logo. + /// + [JsonProperty("logo")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("logo")] +#endif + public PaymentMethodCustomLogo Logo { get; set; } + + /// + /// ID of the Dashboard-only CustomPaymentMethodType. Not expandable. + /// + [JsonProperty("type")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("type")] +#endif + public string Type { get; set; } + } +} diff --git a/src/Stripe.net/Entities/PaymentMethods/PaymentMethodCustomLogo.cs b/src/Stripe.net/Entities/PaymentMethods/PaymentMethodCustomLogo.cs new file mode 100644 index 0000000000..8d85e1ba94 --- /dev/null +++ b/src/Stripe.net/Entities/PaymentMethods/PaymentMethodCustomLogo.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 PaymentMethodCustomLogo : StripeEntity + { + /// + /// Content type of the Dashboard-only CustomPaymentMethodType logo. + /// + [JsonProperty("content_type")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("content_type")] +#endif + public string ContentType { get; set; } + + /// + /// URL of the Dashboard-only CustomPaymentMethodType logo. + /// + [JsonProperty("url")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("url")] +#endif + public string Url { get; set; } + } +} diff --git a/src/Stripe.net/Entities/PaymentRecords/PaymentRecordPaymentMethodDetailsCrypto.cs b/src/Stripe.net/Entities/PaymentRecords/PaymentRecordPaymentMethodDetailsCrypto.cs index e941024ba0..325faf4e61 100644 --- a/src/Stripe.net/Entities/PaymentRecords/PaymentRecordPaymentMethodDetailsCrypto.cs +++ b/src/Stripe.net/Entities/PaymentRecords/PaymentRecordPaymentMethodDetailsCrypto.cs @@ -19,7 +19,7 @@ public class PaymentRecordPaymentMethodDetailsCrypto : StripeEntity /// The blockchain network that the transaction was sent on. - /// One of: base, ethereum, or polygon. + /// One of: base, ethereum, polygon, or solana. /// [JsonProperty("network")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/PaymentRecords/PaymentRecordPaymentMethodDetailsRechnung.cs b/src/Stripe.net/Entities/PaymentRecords/PaymentRecordPaymentMethodDetailsRechnung.cs index f9b11806bb..07c97d3a60 100644 --- a/src/Stripe.net/Entities/PaymentRecords/PaymentRecordPaymentMethodDetailsRechnung.cs +++ b/src/Stripe.net/Entities/PaymentRecords/PaymentRecordPaymentMethodDetailsRechnung.cs @@ -1,7 +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 PaymentRecordPaymentMethodDetailsRechnung : StripeEntity { + /// + /// Payment portal URL. + /// + [JsonProperty("payment_portal_url")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_portal_url")] +#endif + public string PaymentPortalUrl { get; set; } } } diff --git a/src/Stripe.net/Entities/Persons/PersonFutureRequirementsError.cs b/src/Stripe.net/Entities/Persons/PersonFutureRequirementsError.cs index 4fe1910369..19cac76dad 100644 --- a/src/Stripe.net/Entities/Persons/PersonFutureRequirementsError.cs +++ b/src/Stripe.net/Entities/Persons/PersonFutureRequirementsError.cs @@ -39,8 +39,8 @@ public class PersonFutureRequirementsError : StripeEntityinvalid_url_website_incomplete_terms_and_conditions, /// invalid_url_website_incomplete_under_construction, /// invalid_url_website_other, invalid_value_other, - /// unsupported_business_type, verification_directors_mismatch, - /// verification_document_address_mismatch, + /// unsupported_business_type, verification_data_not_found, + /// verification_directors_mismatch, verification_document_address_mismatch, /// verification_document_address_missing, verification_document_corrupt, /// verification_document_country_not_supported, /// verification_document_directors_mismatch, diff --git a/src/Stripe.net/Entities/Persons/PersonRequirementsError.cs b/src/Stripe.net/Entities/Persons/PersonRequirementsError.cs index 29fe1b92ca..9d0a646139 100644 --- a/src/Stripe.net/Entities/Persons/PersonRequirementsError.cs +++ b/src/Stripe.net/Entities/Persons/PersonRequirementsError.cs @@ -39,8 +39,8 @@ public class PersonRequirementsError : StripeEntity /// invalid_url_website_incomplete_terms_and_conditions, /// invalid_url_website_incomplete_under_construction, /// invalid_url_website_other, invalid_value_other, - /// unsupported_business_type, verification_directors_mismatch, - /// verification_document_address_mismatch, + /// unsupported_business_type, verification_data_not_found, + /// verification_directors_mismatch, verification_document_address_mismatch, /// verification_document_address_missing, verification_document_corrupt, /// verification_document_country_not_supported, /// verification_document_directors_mismatch, diff --git a/src/Stripe.net/Entities/Refunds/RefundDestinationDetails.cs b/src/Stripe.net/Entities/Refunds/RefundDestinationDetails.cs index 9275d75fae..0fc8dfe717 100644 --- a/src/Stripe.net/Entities/Refunds/RefundDestinationDetails.cs +++ b/src/Stripe.net/Entities/Refunds/RefundDestinationDetails.cs @@ -68,6 +68,12 @@ public class RefundDestinationDetails : StripeEntity #endif public RefundDestinationDetailsCashapp Cashapp { get; set; } + [JsonProperty("crypto")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("crypto")] +#endif + public RefundDestinationDetailsCrypto Crypto { get; set; } + [JsonProperty("customer_cash_balance")] #if NET6_0_OR_GREATER [STJS.JsonPropertyName("customer_cash_balance")] diff --git a/src/Stripe.net/Entities/Refunds/RefundDestinationDetailsCrypto.cs b/src/Stripe.net/Entities/Refunds/RefundDestinationDetailsCrypto.cs new file mode 100644 index 0000000000..89a70f7619 --- /dev/null +++ b/src/Stripe.net/Entities/Refunds/RefundDestinationDetailsCrypto.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 RefundDestinationDetailsCrypto : StripeEntity + { + /// + /// The transaction hash of the refund. + /// + [JsonProperty("reference")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("reference")] +#endif + public string Reference { get; set; } + } +} diff --git a/src/Stripe.net/Entities/SetupIntents/SetupIntent.cs b/src/Stripe.net/Entities/SetupIntents/SetupIntent.cs index 7ca0c5a8cc..05c14e0f81 100644 --- a/src/Stripe.net/Entities/SetupIntents/SetupIntent.cs +++ b/src/Stripe.net/Entities/SetupIntents/SetupIntent.cs @@ -238,6 +238,27 @@ public Customer Customer #endif public string Description { get; set; } + /// + /// Payment method types that are excluded from this SetupIntent. + /// One of: acss_debit, affirm, afterpay_clearpay, alipay, + /// alma, amazon_pay, au_becs_debit, bacs_debit, + /// bancontact, billie, blik, boleto, card, + /// cashapp, crypto, customer_balance, eps, fpx, + /// giropay, gopay, grabpay, id_bank_transfer, ideal, + /// kakao_pay, klarna, konbini, kr_card, mb_way, + /// mobilepay, multibanco, naver_pay, nz_bank_account, + /// oxxo, p24, pay_by_bank, payco, paynow, paypal, + /// paypay, payto, pix, promptpay, qris, rechnung, + /// revolut_pay, samsung_pay, satispay, sepa_debit, + /// shopeepay, sofort, stripe_balance, swish, twint, + /// us_bank_account, wechat_pay, or zip. + /// + [JsonProperty("excluded_payment_method_types")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("excluded_payment_method_types")] +#endif + public List ExcludedPaymentMethodTypes { get; set; } + /// /// Indicates the directions of money movement for which this payment method is intended to /// be used. diff --git a/src/Stripe.net/Entities/Tax/Registrations/RegistrationCountryOptions.cs b/src/Stripe.net/Entities/Tax/Registrations/RegistrationCountryOptions.cs index f34e658506..c986b1ec4a 100644 --- a/src/Stripe.net/Entities/Tax/Registrations/RegistrationCountryOptions.cs +++ b/src/Stripe.net/Entities/Tax/Registrations/RegistrationCountryOptions.cs @@ -542,6 +542,12 @@ public class RegistrationCountryOptions : StripeEntity + { + /// + /// Type of registration in country. + /// + [JsonProperty("type")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("type")] +#endif + public string Type { get; set; } + } +} diff --git a/src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTipping.cs b/src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTipping.cs index f4a9596b30..d3d7b5ede1 100644 --- a/src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTipping.cs +++ b/src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTipping.cs @@ -62,6 +62,12 @@ public class ConfigurationTipping : StripeEntity #endif public ConfigurationTippingGbp Gbp { get; set; } + [JsonProperty("gip")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("gip")] +#endif + public ConfigurationTippingGip Gip { get; set; } + [JsonProperty("hkd")] #if NET6_0_OR_GREATER [STJS.JsonPropertyName("hkd")] diff --git a/src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTippingGip.cs b/src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTippingGip.cs new file mode 100644 index 0000000000..f696b2a5d6 --- /dev/null +++ b/src/Stripe.net/Entities/Terminal/Configurations/ConfigurationTippingGip.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 ConfigurationTippingGip : 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/Entities/Terminal/Readers/Reader.cs b/src/Stripe.net/Entities/Terminal/Readers/Reader.cs index 1aa25c1675..f6dc32f7f1 100644 --- a/src/Stripe.net/Entities/Terminal/Readers/Reader.cs +++ b/src/Stripe.net/Entities/Terminal/Readers/Reader.cs @@ -1,6 +1,7 @@ // File generated from our OpenAPI spec namespace Stripe.Terminal { + using System; using System.Collections.Generic; using Newtonsoft.Json; using Stripe.Infrastructure; @@ -96,6 +97,17 @@ public class Reader : StripeEntity, IHasId, IHasMetadata, IHasObject #endif public string Label { get; set; } + /// + /// The last time this reader reported to Stripe backend. + /// + [JsonProperty("last_seen_at")] + [JsonConverter(typeof(UnixDateTimeConverter))] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("last_seen_at")] + [STJS.JsonConverter(typeof(STJUnixDateTimeConverter))] +#endif + public DateTime? LastSeenAt { get; set; } + /// /// Has the value true if the object exists in live mode or the value false if /// the object exists in test mode. diff --git a/src/Stripe.net/Entities/Terminal/Readers/ReaderActionCollectInputsInputSelectionChoice.cs b/src/Stripe.net/Entities/Terminal/Readers/ReaderActionCollectInputsInputSelectionChoice.cs index 77dd430edb..3ea637ac2d 100644 --- a/src/Stripe.net/Entities/Terminal/Readers/ReaderActionCollectInputsInputSelectionChoice.cs +++ b/src/Stripe.net/Entities/Terminal/Readers/ReaderActionCollectInputsInputSelectionChoice.cs @@ -9,7 +9,7 @@ namespace Stripe.Terminal public class ReaderActionCollectInputsInputSelectionChoice : StripeEntity, IHasId { /// - /// The id to be selected. + /// The identifier for the selected choice. Maximum 50 characters. /// [JsonProperty("id")] #if NET6_0_OR_GREATER @@ -18,7 +18,7 @@ public class ReaderActionCollectInputsInputSelectionChoice : StripeEntity - /// The button style for the choice. + /// The button style for the choice. Can be primary or secondary. /// One of: primary, or secondary. /// [JsonProperty("style")] @@ -28,7 +28,7 @@ public class ReaderActionCollectInputsInputSelectionChoice : StripeEntity - /// The text to be selected. + /// The text to be selected. Maximum 30 characters. /// [JsonProperty("text")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/Terminal/Readers/ReaderActionCollectInputsInputToggle.cs b/src/Stripe.net/Entities/Terminal/Readers/ReaderActionCollectInputsInputToggle.cs index 7d93656950..7c3c7f2dc9 100644 --- a/src/Stripe.net/Entities/Terminal/Readers/ReaderActionCollectInputsInputToggle.cs +++ b/src/Stripe.net/Entities/Terminal/Readers/ReaderActionCollectInputsInputToggle.cs @@ -9,7 +9,7 @@ namespace Stripe.Terminal public class ReaderActionCollectInputsInputToggle : StripeEntity { /// - /// The toggle's default value. + /// The toggle's default value. Can be enabled or disabled. /// One of: disabled, or enabled. /// [JsonProperty("default_value")] @@ -19,7 +19,7 @@ public class ReaderActionCollectInputsInputToggle : StripeEntity - /// The toggle's description text. + /// The toggle's description text. Maximum 50 characters. /// [JsonProperty("description")] #if NET6_0_OR_GREATER @@ -28,7 +28,7 @@ public class ReaderActionCollectInputsInputToggle : StripeEntity - /// The toggle's title text. + /// The toggle's title text. Maximum 50 characters. /// [JsonProperty("title")] #if NET6_0_OR_GREATER @@ -37,7 +37,7 @@ public class ReaderActionCollectInputsInputToggle : StripeEntity - /// The toggle's collected value. + /// The toggle's collected value. Can be enabled or disabled. /// One of: disabled, or enabled. /// [JsonProperty("value")] diff --git a/src/Stripe.net/Entities/Terminal/Readers/ReaderActionSetReaderDisplay.cs b/src/Stripe.net/Entities/Terminal/Readers/ReaderActionSetReaderDisplay.cs index 531eccf2d6..607bf739f2 100644 --- a/src/Stripe.net/Entities/Terminal/Readers/ReaderActionSetReaderDisplay.cs +++ b/src/Stripe.net/Entities/Terminal/Readers/ReaderActionSetReaderDisplay.cs @@ -9,7 +9,7 @@ namespace Stripe.Terminal public class ReaderActionSetReaderDisplay : StripeEntity { /// - /// Cart object to be displayed by the reader. + /// Cart object to be displayed by the reader, including line items, amounts, and currency. /// [JsonProperty("cart")] #if NET6_0_OR_GREATER @@ -18,7 +18,8 @@ public class ReaderActionSetReaderDisplay : StripeEntity - /// Type of information to be displayed by the reader. + /// Type of information to be displayed by the reader. Only cart is currently + /// supported. /// [JsonProperty("type")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/V2/Billing/Cadences/CadenceSettingsDataCollectionEmailDelivery.cs b/src/Stripe.net/Entities/V2/Billing/Cadences/CadenceSettingsDataCollectionEmailDelivery.cs index d29b221537..8f93d1dca8 100644 --- a/src/Stripe.net/Entities/V2/Billing/Cadences/CadenceSettingsDataCollectionEmailDelivery.cs +++ b/src/Stripe.net/Entities/V2/Billing/Cadences/CadenceSettingsDataCollectionEmailDelivery.cs @@ -9,8 +9,8 @@ namespace Stripe.V2.Billing public class CadenceSettingsDataCollectionEmailDelivery : StripeEntity { /// - /// Controls emails for when the payment is due. For example after the invoice is finilized - /// and transition to Open state. + /// Controls emails for when the payment is due. For example after the invoice is finalized + /// and transitions to Open state. /// [JsonProperty("payment_due")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/V2/Billing/Cadences/CadenceSettingsDataCollectionEmailDeliveryPaymentDue.cs b/src/Stripe.net/Entities/V2/Billing/Cadences/CadenceSettingsDataCollectionEmailDeliveryPaymentDue.cs index 02b17ef660..ac46824ce7 100644 --- a/src/Stripe.net/Entities/V2/Billing/Cadences/CadenceSettingsDataCollectionEmailDeliveryPaymentDue.cs +++ b/src/Stripe.net/Entities/V2/Billing/Cadences/CadenceSettingsDataCollectionEmailDeliveryPaymentDue.cs @@ -18,7 +18,7 @@ public class CadenceSettingsDataCollectionEmailDeliveryPaymentDue : StripeEntity public bool Enabled { get; set; } /// - /// If true the payment link to hosted invocie page would be included in email and PDF of + /// If true the payment link to hosted invoice page would be included in email and PDF of /// the invoice. /// [JsonProperty("include_payment_link")] diff --git a/src/Stripe.net/Entities/V2/Billing/CollectionSettingVersions/CollectionSettingVersionEmailDelivery.cs b/src/Stripe.net/Entities/V2/Billing/CollectionSettingVersions/CollectionSettingVersionEmailDelivery.cs index 7f91483619..60a15c418a 100644 --- a/src/Stripe.net/Entities/V2/Billing/CollectionSettingVersions/CollectionSettingVersionEmailDelivery.cs +++ b/src/Stripe.net/Entities/V2/Billing/CollectionSettingVersions/CollectionSettingVersionEmailDelivery.cs @@ -9,8 +9,8 @@ namespace Stripe.V2.Billing public class CollectionSettingVersionEmailDelivery : StripeEntity { /// - /// Controls emails for when the payment is due. For example after the invoice is finilized - /// and transition to Open state. + /// Controls emails for when the payment is due. For example after the invoice is finalized + /// and transitions to Open state. /// [JsonProperty("payment_due")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/V2/Billing/CollectionSettingVersions/CollectionSettingVersionEmailDeliveryPaymentDue.cs b/src/Stripe.net/Entities/V2/Billing/CollectionSettingVersions/CollectionSettingVersionEmailDeliveryPaymentDue.cs index 950870c1b8..c38b0f351e 100644 --- a/src/Stripe.net/Entities/V2/Billing/CollectionSettingVersions/CollectionSettingVersionEmailDeliveryPaymentDue.cs +++ b/src/Stripe.net/Entities/V2/Billing/CollectionSettingVersions/CollectionSettingVersionEmailDeliveryPaymentDue.cs @@ -18,7 +18,7 @@ public class CollectionSettingVersionEmailDeliveryPaymentDue : StripeEntity - /// If true the payment link to hosted invocie page would be included in email and PDF of + /// If true the payment link to hosted invoice page would be included in email and PDF of /// the invoice. /// [JsonProperty("include_payment_link")] diff --git a/src/Stripe.net/Entities/V2/Billing/CollectionSettings/CollectionSettingEmailDelivery.cs b/src/Stripe.net/Entities/V2/Billing/CollectionSettings/CollectionSettingEmailDelivery.cs index 709ad0a5aa..b70429659b 100644 --- a/src/Stripe.net/Entities/V2/Billing/CollectionSettings/CollectionSettingEmailDelivery.cs +++ b/src/Stripe.net/Entities/V2/Billing/CollectionSettings/CollectionSettingEmailDelivery.cs @@ -9,8 +9,8 @@ namespace Stripe.V2.Billing public class CollectionSettingEmailDelivery : StripeEntity { /// - /// Controls emails for when the payment is due. For example after the invoice is finilized - /// and transition to Open state. + /// Controls emails for when the payment is due. For example after the invoice is finalized + /// and transitions to Open state. /// [JsonProperty("payment_due")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/V2/Billing/CollectionSettings/CollectionSettingEmailDeliveryPaymentDue.cs b/src/Stripe.net/Entities/V2/Billing/CollectionSettings/CollectionSettingEmailDeliveryPaymentDue.cs index 8da3f0eca0..1bc5a75e61 100644 --- a/src/Stripe.net/Entities/V2/Billing/CollectionSettings/CollectionSettingEmailDeliveryPaymentDue.cs +++ b/src/Stripe.net/Entities/V2/Billing/CollectionSettings/CollectionSettingEmailDeliveryPaymentDue.cs @@ -18,7 +18,7 @@ public class CollectionSettingEmailDeliveryPaymentDue : StripeEntity - /// If true the payment link to hosted invocie page would be included in email and PDF of + /// If true the payment link to hosted invoice page would be included in email and PDF of /// the invoice. /// [JsonProperty("include_payment_link")] diff --git a/src/Stripe.net/Entities/V2/Core/Accounts/Account.cs b/src/Stripe.net/Entities/V2/Core/Accounts/Account.cs index 4aee7f12fd..94ef1259ea 100644 --- a/src/Stripe.net/Entities/V2/Core/Accounts/Account.cs +++ b/src/Stripe.net/Entities/V2/Core/Accounts/Account.cs @@ -45,6 +45,15 @@ public class Account : StripeEntity, IHasId, IHasMetadata, IHasObject #endif public List AppliedConfigurations { get; set; } + /// + /// A value indicating if the Account has been closed. + /// + [JsonProperty("closed")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("closed")] +#endif + public bool? Closed { get; set; } + /// /// An Account Configuration which allows the Account to take on a key persona across Stripe /// products. diff --git a/src/Stripe.net/Entities/V2/Core/Accounts/AccountConfigurationCustomerAutomaticIndirectTax.cs b/src/Stripe.net/Entities/V2/Core/Accounts/AccountConfigurationCustomerAutomaticIndirectTax.cs index 53f9c6a965..bec45585f2 100644 --- a/src/Stripe.net/Entities/V2/Core/Accounts/AccountConfigurationCustomerAutomaticIndirectTax.cs +++ b/src/Stripe.net/Entities/V2/Core/Accounts/AccountConfigurationCustomerAutomaticIndirectTax.cs @@ -43,7 +43,8 @@ public class AccountConfigurationCustomerAutomaticIndirectTax : StripeEntityidentity_address, ip_address, or shipping_address. + /// One of: identity_address, ip_address, payment_method, or + /// shipping_address. /// [JsonProperty("location_source")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/V2/Core/Accounts/AccountConfigurationStorerCapabilitiesHoldsCurrencies.cs b/src/Stripe.net/Entities/V2/Core/Accounts/AccountConfigurationStorerCapabilitiesHoldsCurrencies.cs index 73c82b8f10..3f76c6fa80 100644 --- a/src/Stripe.net/Entities/V2/Core/Accounts/AccountConfigurationStorerCapabilitiesHoldsCurrencies.cs +++ b/src/Stripe.net/Entities/V2/Core/Accounts/AccountConfigurationStorerCapabilitiesHoldsCurrencies.cs @@ -16,5 +16,14 @@ public class AccountConfigurationStorerCapabilitiesHoldsCurrencies : StripeEntit [STJS.JsonPropertyName("gbp")] #endif public AccountConfigurationStorerCapabilitiesHoldsCurrenciesGbp Gbp { get; set; } + + /// + /// Can hold storage-type funds on Stripe in USD. + /// + [JsonProperty("usd")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("usd")] +#endif + public AccountConfigurationStorerCapabilitiesHoldsCurrenciesUsd Usd { get; set; } } } diff --git a/src/Stripe.net/Entities/V2/Core/Accounts/AccountConfigurationStorerCapabilitiesHoldsCurrenciesUsd.cs b/src/Stripe.net/Entities/V2/Core/Accounts/AccountConfigurationStorerCapabilitiesHoldsCurrenciesUsd.cs new file mode 100644 index 0000000000..bf2d5bfa66 --- /dev/null +++ b/src/Stripe.net/Entities/V2/Core/Accounts/AccountConfigurationStorerCapabilitiesHoldsCurrenciesUsd.cs @@ -0,0 +1,41 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core +{ + using System.Collections.Generic; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountConfigurationStorerCapabilitiesHoldsCurrenciesUsd : StripeEntity + { + /// + /// Whether the Capability has been requested. + /// + [JsonProperty("requested")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("requested")] +#endif + public bool Requested { get; set; } + + /// + /// The status of the Capability. + /// One of: active, pending, restricted, or unsupported. + /// + [JsonProperty("status")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("status")] +#endif + public string Status { get; set; } + + /// + /// Additional details regarding the status of the Capability. status_details will be + /// empty if the Capability's status is active. + /// + [JsonProperty("status_details")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("status_details")] +#endif + public List StatusDetails { get; set; } + } +} diff --git a/src/Stripe.net/Entities/V2/Core/Accounts/AccountConfigurationStorerCapabilitiesHoldsCurrenciesUsdStatusDetail.cs b/src/Stripe.net/Entities/V2/Core/Accounts/AccountConfigurationStorerCapabilitiesHoldsCurrenciesUsdStatusDetail.cs new file mode 100644 index 0000000000..d817755596 --- /dev/null +++ b/src/Stripe.net/Entities/V2/Core/Accounts/AccountConfigurationStorerCapabilitiesHoldsCurrenciesUsdStatusDetail.cs @@ -0,0 +1,35 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountConfigurationStorerCapabilitiesHoldsCurrenciesUsdStatusDetail : StripeEntity + { + /// + /// Machine-readable code explaining the reason for the Capability to be in its current + /// status. + /// One of: determining_status, requirements_past_due, + /// requirements_pending_verification, restricted_other, + /// unsupported_business, unsupported_country, or + /// unsupported_entity_type. + /// + [JsonProperty("code")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("code")] +#endif + public string Code { get; set; } + + /// + /// Machine-readable code explaining how to make the Capability active. + /// One of: contact_stripe, no_resolution, or provide_info. + /// + [JsonProperty("resolution")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("resolution")] +#endif + public string Resolution { get; set; } + } +} diff --git a/src/Stripe.net/Entities/V2/Core/Accounts/AccountDefaultsResponsibilities.cs b/src/Stripe.net/Entities/V2/Core/Accounts/AccountDefaultsResponsibilities.cs index ed8836ccd0..76a570ea2e 100644 --- a/src/Stripe.net/Entities/V2/Core/Accounts/AccountDefaultsResponsibilities.cs +++ b/src/Stripe.net/Entities/V2/Core/Accounts/AccountDefaultsResponsibilities.cs @@ -11,7 +11,8 @@ public class AccountDefaultsResponsibilities : StripeEntity /// A value indicating the responsible payer of a bundle of Stripe fees for pricing-control /// eligible products on this Account. - /// One of: application, or stripe. + /// One of: application, application_custom, application_express, or + /// stripe. /// [JsonProperty("fees_collector")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/V2/Core/Accounts/AccountIdentity.cs b/src/Stripe.net/Entities/V2/Core/Accounts/AccountIdentity.cs index d15bee9335..be70f24088 100644 --- a/src/Stripe.net/Entities/V2/Core/Accounts/AccountIdentity.cs +++ b/src/Stripe.net/Entities/V2/Core/Accounts/AccountIdentity.cs @@ -9,7 +9,8 @@ namespace Stripe.V2.Core public class AccountIdentity : StripeEntity { /// - /// Attestations from the identity's key people, e.g. owners, executives, directors. + /// Attestations from the identity's key people, e.g. owners, executives, directors, + /// representatives. /// [JsonProperty("attestations")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Entities/V2/Core/Accounts/AccountIdentityAttestations.cs b/src/Stripe.net/Entities/V2/Core/Accounts/AccountIdentityAttestations.cs index 37862d4a6c..e79e0b93ed 100644 --- a/src/Stripe.net/Entities/V2/Core/Accounts/AccountIdentityAttestations.cs +++ b/src/Stripe.net/Entities/V2/Core/Accounts/AccountIdentityAttestations.cs @@ -37,6 +37,16 @@ public class AccountIdentityAttestations : StripeEntity + /// This hash is used to attest that the representative is authorized to act as the + /// representative of their legal entity. + /// + [JsonProperty("representative_declaration")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("representative_declaration")] +#endif + public AccountIdentityAttestationsRepresentativeDeclaration RepresentativeDeclaration { get; set; } + /// /// Attestations of accepted terms of service agreements. /// diff --git a/src/Stripe.net/Entities/V2/Core/Accounts/AccountIdentityAttestationsRepresentativeDeclaration.cs b/src/Stripe.net/Entities/V2/Core/Accounts/AccountIdentityAttestationsRepresentativeDeclaration.cs new file mode 100644 index 0000000000..9baf35a2a7 --- /dev/null +++ b/src/Stripe.net/Entities/V2/Core/Accounts/AccountIdentityAttestationsRepresentativeDeclaration.cs @@ -0,0 +1,41 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core +{ + using System; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountIdentityAttestationsRepresentativeDeclaration : StripeEntity + { + /// + /// The time marking when the representative attestation was made. Represented as a RFC 3339 + /// date & time UTC value in millisecond precision, for example: + /// 2022-09-18T13:22:18.123Z. + /// + [JsonProperty("date")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("date")] +#endif + public DateTime? Date { get; set; } = Stripe.Infrastructure.DateTimeUtils.UnixEpoch; + + /// + /// The IP address from which the representative 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 representative 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/Entities/V2/Core/Accounts/AccountRequirementsEntryImpactRestrictsCapability.cs b/src/Stripe.net/Entities/V2/Core/Accounts/AccountRequirementsEntryImpactRestrictsCapability.cs index 92ce0e5c67..6e9bcf8f15 100644 --- a/src/Stripe.net/Entities/V2/Core/Accounts/AccountRequirementsEntryImpactRestrictsCapability.cs +++ b/src/Stripe.net/Entities/V2/Core/Accounts/AccountRequirementsEntryImpactRestrictsCapability.cs @@ -18,7 +18,8 @@ public class AccountRequirementsEntryImpactRestrictsCapability : StripeEntitycard_payments, cartes_bancaires_payments, cashapp_payments, /// eps_payments, financial_addresses.bank_accounts, fpx_payments, /// gb_bank_transfer_payments, grabpay_payments, holds_currencies.gbp, - /// ideal_payments, inbound_transfers.financial_accounts, jcb_payments, + /// holds_currencies.usd, ideal_payments, + /// inbound_transfers.financial_accounts, jcb_payments, /// jp_bank_transfer_payments, kakao_pay_payments, klarna_payments, /// konbini_payments, kr_card_payments, link_payments, /// mobilepay_payments, multibanco_payments, mx_bank_transfer_payments, diff --git a/src/Stripe.net/Entities/V2/Core/Vault/UsBankAccounts/UsBankAccount.cs b/src/Stripe.net/Entities/V2/Core/Vault/UsBankAccounts/UsBankAccount.cs index ec9a7eedea..189a20e6d0 100644 --- a/src/Stripe.net/Entities/V2/Core/Vault/UsBankAccounts/UsBankAccount.cs +++ b/src/Stripe.net/Entities/V2/Core/Vault/UsBankAccounts/UsBankAccount.cs @@ -106,5 +106,14 @@ public class UsBankAccount : StripeEntity, IHasId, IHasObject [STJS.JsonPropertyName("routing_number")] #endif public string RoutingNumber { get; set; } + + /// + /// The bank account verification details. + /// + [JsonProperty("verification")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("verification")] +#endif + public UsBankAccountVerification Verification { get; set; } } } diff --git a/src/Stripe.net/Entities/V2/Core/Vault/UsBankAccounts/UsBankAccountVerification.cs b/src/Stripe.net/Entities/V2/Core/Vault/UsBankAccounts/UsBankAccountVerification.cs new file mode 100644 index 0000000000..fbd003dc9c --- /dev/null +++ b/src/Stripe.net/Entities/V2/Core/Vault/UsBankAccounts/UsBankAccountVerification.cs @@ -0,0 +1,31 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core.Vault +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class UsBankAccountVerification : StripeEntity + { + /// + /// The microdeposit verification details if the status is awaiting verification. + /// + [JsonProperty("microdeposit_verification_details")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("microdeposit_verification_details")] +#endif + public UsBankAccountVerificationMicrodepositVerificationDetails MicrodepositVerificationDetails { get; set; } + + /// + /// The bank account verification status. + /// One of: awaiting_verification, unverified, verification_failed, or + /// verified. + /// + [JsonProperty("status")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("status")] +#endif + public string Status { get; set; } + } +} diff --git a/src/Stripe.net/Entities/V2/Core/Vault/UsBankAccounts/UsBankAccountVerificationMicrodepositVerificationDetails.cs b/src/Stripe.net/Entities/V2/Core/Vault/UsBankAccounts/UsBankAccountVerificationMicrodepositVerificationDetails.cs new file mode 100644 index 0000000000..6515d1434a --- /dev/null +++ b/src/Stripe.net/Entities/V2/Core/Vault/UsBankAccounts/UsBankAccountVerificationMicrodepositVerificationDetails.cs @@ -0,0 +1,40 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core.Vault +{ + using System; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class UsBankAccountVerificationMicrodepositVerificationDetails : StripeEntity + { + /// + /// Time when microdeposits will expire and have to be re-sent. + /// + [JsonProperty("expires")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("expires")] +#endif + public DateTime Expires { get; set; } = Stripe.Infrastructure.DateTimeUtils.UnixEpoch; + + /// + /// Microdeposit type can be amounts or descriptor_type. + /// One of: amounts, or descriptor_code. + /// + [JsonProperty("microdeposit_type")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("microdeposit_type")] +#endif + public string MicrodepositType { get; set; } + + /// + /// Time when microdeposits were sent. + /// + [JsonProperty("sent")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("sent")] +#endif + public DateTime Sent { get; set; } = Stripe.Infrastructure.DateTimeUtils.UnixEpoch; + } +} diff --git a/src/Stripe.net/Events/V2BillingBillSettingUpdatedEvent.cs b/src/Stripe.net/Events/V2BillingBillSettingUpdatedEvent.cs deleted file mode 100644 index 810c8b57e6..0000000000 --- a/src/Stripe.net/Events/V2BillingBillSettingUpdatedEvent.cs +++ /dev/null @@ -1,52 +0,0 @@ -// File generated from our OpenAPI spec -namespace Stripe.Events -{ - using System.Threading.Tasks; - using Newtonsoft.Json; -#if NET6_0_OR_GREATER - using STJS = System.Text.Json.Serialization; -#endif - - /// - /// This event occurs when a bill setting is updated. - /// - public class V2BillingBillSettingUpdatedEvent : V2.Core.Event - { - /// - /// Data for the v2.billing.bill_setting.updated event. - /// - [JsonProperty("data")] -#if NET6_0_OR_GREATER - [STJS.JsonPropertyName("data")] -#endif - - public V2BillingBillSettingUpdatedEventData Data { get; set; } - - /// - /// Object containing the reference to API resource relevant to the event. - /// - [JsonProperty("related_object")] -#if NET6_0_OR_GREATER - [STJS.JsonPropertyName("related_object")] -#endif - - public V2.Core.EventRelatedObject RelatedObject { get; set; } - - /// - /// Asynchronously retrieves the related object from the API. Make an API request on every - /// call. - /// - public Task FetchRelatedObjectAsync() - { - return this.FetchRelatedObjectAsync(this.RelatedObject); - } - - /// - /// Retrieves the related object from the API. Make an API request on every call. - /// - public V2.Billing.BillSetting FetchRelatedObject() - { - return this.FetchRelatedObject(this.RelatedObject); - } - } -} diff --git a/src/Stripe.net/Events/V2BillingBillSettingUpdatedEventData.cs b/src/Stripe.net/Events/V2BillingBillSettingUpdatedEventData.cs deleted file mode 100644 index 7a36fba0bf..0000000000 --- a/src/Stripe.net/Events/V2BillingBillSettingUpdatedEventData.cs +++ /dev/null @@ -1,22 +0,0 @@ -// File generated from our OpenAPI spec -namespace Stripe.Events -{ - using System; - using System.Threading.Tasks; - using Newtonsoft.Json; -#if NET6_0_OR_GREATER - using STJS = System.Text.Json.Serialization; -#endif - - public class V2BillingBillSettingUpdatedEventData : StripeEntity - { - /// - /// Timestamp of when the object was updated. - /// - [JsonProperty("updated")] -#if NET6_0_OR_GREATER - [STJS.JsonPropertyName("updated")] -#endif - public DateTime Updated { get; set; } = Stripe.Infrastructure.DateTimeUtils.UnixEpoch; - } -} diff --git a/src/Stripe.net/Events/V2BillingBillSettingUpdatedEventNotification.cs b/src/Stripe.net/Events/V2BillingBillSettingUpdatedEventNotification.cs deleted file mode 100644 index bc8a718dd4..0000000000 --- a/src/Stripe.net/Events/V2BillingBillSettingUpdatedEventNotification.cs +++ /dev/null @@ -1,53 +0,0 @@ -// File generated from our OpenAPI spec -namespace Stripe.Events -{ - using System.Threading.Tasks; - using Newtonsoft.Json; - using Stripe.V2; -#if NET6_0_OR_GREATER - using STJS = System.Text.Json.Serialization; -#endif - - /// - /// This event occurs when a bill setting is updated. - /// - public class V2BillingBillSettingUpdatedEventNotification : V2.Core.EventNotification - { - /// - /// Object containing the reference to API resource relevant to the event. - /// - [JsonProperty("related_object")] -#if NET6_0_OR_GREATER - [STJS.JsonPropertyName("related_object")] -#endif - - public V2.Core.EventNotificationRelatedObject RelatedObject { get; set; } - - /// - /// Asynchronously retrieves the related object from the API. Make an API request on every - /// call. - /// - public Task FetchRelatedObjectAsync() - { - return this.FetchRelatedObjectAsync(this.RelatedObject); - } - - /// - /// Retrieves the related object from the API. Make an API request on every call. - /// - public V2.Billing.BillSetting FetchRelatedObject() - { - return this.FetchRelatedObject(this.RelatedObject); - } - - public V2BillingBillSettingUpdatedEvent FetchEvent() - { - return this.FetchEvent(); - } - - public Task FetchEventAsync() - { - return this.FetchEventAsync(); - } - } -} diff --git a/src/Stripe.net/Events/V2MoneyManagementTransactionCreatedEvent.cs b/src/Stripe.net/Events/V2MoneyManagementTransactionCreatedEvent.cs index fd95237ebb..1bb06b3bba 100644 --- a/src/Stripe.net/Events/V2MoneyManagementTransactionCreatedEvent.cs +++ b/src/Stripe.net/Events/V2MoneyManagementTransactionCreatedEvent.cs @@ -12,6 +12,16 @@ namespace Stripe.Events /// public class V2MoneyManagementTransactionCreatedEvent : V2.Core.Event { + /// + /// Data for the v2.money_management.transaction.created event. + /// + [JsonProperty("data")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("data")] +#endif + + public V2MoneyManagementTransactionCreatedEventData Data { get; set; } + /// /// Object containing the reference to API resource relevant to the event. /// diff --git a/src/Stripe.net/Events/V2MoneyManagementTransactionCreatedEventData.cs b/src/Stripe.net/Events/V2MoneyManagementTransactionCreatedEventData.cs new file mode 100644 index 0000000000..d87f23a852 --- /dev/null +++ b/src/Stripe.net/Events/V2MoneyManagementTransactionCreatedEventData.cs @@ -0,0 +1,21 @@ +// File generated from our OpenAPI spec +namespace Stripe.Events +{ + using System.Threading.Tasks; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class V2MoneyManagementTransactionCreatedEventData : StripeEntity + { + /// + /// Id of the v1 Transaction corresponding to this Transaction. + /// + [JsonProperty("v1_id")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("v1_id")] +#endif + public string V1Id { get; set; } + } +} diff --git a/src/Stripe.net/Infrastructure/Public/StripeTypeRegistry.cs b/src/Stripe.net/Infrastructure/Public/StripeTypeRegistry.cs index 0863a4e293..5f00d70976 100644 --- a/src/Stripe.net/Infrastructure/Public/StripeTypeRegistry.cs +++ b/src/Stripe.net/Infrastructure/Public/StripeTypeRegistry.cs @@ -314,10 +314,6 @@ public static class StripeTypeRegistry "v1.billing.meter.no_meter_found", typeof( Events.V1BillingMeterNoMeterFoundEvent) }, - { - "v2.billing.bill_setting.updated", typeof( - Events.V2BillingBillSettingUpdatedEvent) - }, { "v2.core.account.closed", typeof(Events.V2CoreAccountClosedEvent) }, { "v2.core.account.created", typeof(Events.V2CoreAccountCreatedEvent) }, { "v2.core.account.updated", typeof(Events.V2CoreAccountUpdatedEvent) }, @@ -569,10 +565,6 @@ public static class StripeTypeRegistry "v1.billing.meter.no_meter_found", typeof( Events.V1BillingMeterNoMeterFoundEventNotification) }, - { - "v2.billing.bill_setting.updated", typeof( - Events.V2BillingBillSettingUpdatedEventNotification) - }, { "v2.core.account.closed", typeof( Events.V2CoreAccountClosedEventNotification) diff --git a/src/Stripe.net/Services/Accounts/AccountCompanyOptions.cs b/src/Stripe.net/Services/Accounts/AccountCompanyOptions.cs index 27b2840094..e6782175c2 100644 --- a/src/Stripe.net/Services/Accounts/AccountCompanyOptions.cs +++ b/src/Stripe.net/Services/Accounts/AccountCompanyOptions.cs @@ -184,6 +184,16 @@ public class AccountCompanyOptions : INestedOptions #endif public string RegistrationNumber { get; set; } + /// + /// This hash is used to attest that the representative is authorized to act as the + /// representative of their legal entity. + /// + [JsonProperty("representative_declaration")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("representative_declaration")] +#endif + public AccountCompanyRepresentativeDeclarationOptions RepresentativeDeclaration { get; set; } + /// /// The category identifying the legal structure of the company or legal entity. See Business diff --git a/src/Stripe.net/Services/Accounts/AccountCompanyRepresentativeDeclarationOptions.cs b/src/Stripe.net/Services/Accounts/AccountCompanyRepresentativeDeclarationOptions.cs new file mode 100644 index 0000000000..f6f1472f95 --- /dev/null +++ b/src/Stripe.net/Services/Accounts/AccountCompanyRepresentativeDeclarationOptions.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 AccountCompanyRepresentativeDeclarationOptions : INestedOptions + { + /// + /// The Unix timestamp marking when the representative 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 representative 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 representative 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/Billing/CreditGrants/CreditGrantCreateOptions.cs b/src/Stripe.net/Services/Billing/CreditGrants/CreditGrantCreateOptions.cs index 0ac9de69e0..1b38129ded 100644 --- a/src/Stripe.net/Services/Billing/CreditGrants/CreditGrantCreateOptions.cs +++ b/src/Stripe.net/Services/Billing/CreditGrants/CreditGrantCreateOptions.cs @@ -32,7 +32,7 @@ public class CreditGrantCreateOptions : BaseOptions, IHasMetadata public CreditGrantApplicabilityConfigOptions ApplicabilityConfig { get; set; } /// - /// The category of this credit grant. + /// The category of this credit grant. It defaults to paid if not specified. /// One of: paid, or promotional. /// [JsonProperty("category")] diff --git a/src/Stripe.net/Services/BillingPortal/Configurations/ConfigurationFeaturesPaymentMethodUpdateOptions.cs b/src/Stripe.net/Services/BillingPortal/Configurations/ConfigurationFeaturesPaymentMethodUpdateOptions.cs index 3e3b0b0172..1f3f32d618 100644 --- a/src/Stripe.net/Services/BillingPortal/Configurations/ConfigurationFeaturesPaymentMethodUpdateOptions.cs +++ b/src/Stripe.net/Services/BillingPortal/Configurations/ConfigurationFeaturesPaymentMethodUpdateOptions.cs @@ -16,5 +16,18 @@ public class ConfigurationFeaturesPaymentMethodUpdateOptions : INestedOptions [STJS.JsonPropertyName("enabled")] #endif public bool? Enabled { get; set; } + + /// + /// The Payment Method + /// Configuration to use for this portal session. When specified, customers will be able + /// to update their payment method to one of the options specified by the payment method + /// configuration. If not set or set to an empty string, the default payment method + /// configuration is used. + /// + [JsonProperty("payment_method_configuration")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_configuration")] +#endif + public string PaymentMethodConfiguration { get; set; } } } diff --git a/src/Stripe.net/Services/Checkout/Sessions/SessionBrandingSettingsOptions.cs b/src/Stripe.net/Services/Checkout/Sessions/SessionBrandingSettingsOptions.cs index 9bb3d95a40..017f5db46a 100644 --- a/src/Stripe.net/Services/Checkout/Sessions/SessionBrandingSettingsOptions.cs +++ b/src/Stripe.net/Services/Checkout/Sessions/SessionBrandingSettingsOptions.cs @@ -39,7 +39,9 @@ public class SessionBrandingSettingsOptions : INestedOptions public string ButtonColor { get; set; } /// - /// A string to override the business name shown on the Checkout Session. + /// A string to override the business name shown on the Checkout Session. This only shows at + /// the top of the Checkout page, and your business name still appears in terms, receipts, + /// and other places. /// [JsonProperty("display_name")] #if NET6_0_OR_GREATER @@ -66,7 +68,7 @@ public class SessionBrandingSettingsOptions : INestedOptions public string FontFamily { get; set; } /// - /// The icon for the Checkout Session. You cannot set both logo and icon. + /// The icon for the Checkout Session. For best results, use a square image. /// [JsonProperty("icon")] #if NET6_0_OR_GREATER @@ -75,7 +77,7 @@ public class SessionBrandingSettingsOptions : INestedOptions public SessionBrandingSettingsIconOptions Icon { get; set; } /// - /// The logo for the Checkout Session. You cannot set both logo and icon. + /// The logo for the Checkout Session. /// [JsonProperty("logo")] #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 f47999ccc7..1a647872ca 100644 --- a/src/Stripe.net/Services/Checkout/Sessions/SessionPaymentMethodOptionsOptions.cs +++ b/src/Stripe.net/Services/Checkout/Sessions/SessionPaymentMethodOptionsOptions.cs @@ -386,6 +386,15 @@ public class SessionPaymentMethodOptionsOptions : INestedOptions #endif public SessionPaymentMethodOptionsSwishOptions Swish { get; set; } + /// + /// contains details about the TWINT payment method options. + /// + [JsonProperty("twint")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("twint")] +#endif + public SessionPaymentMethodOptionsTwintOptions Twint { get; set; } + /// /// contains details about the Us Bank Account payment method options. /// diff --git a/src/Stripe.net/Services/Checkout/Sessions/SessionPaymentMethodOptionsTwintOptions.cs b/src/Stripe.net/Services/Checkout/Sessions/SessionPaymentMethodOptionsTwintOptions.cs new file mode 100644 index 0000000000..75a9f86437 --- /dev/null +++ b/src/Stripe.net/Services/Checkout/Sessions/SessionPaymentMethodOptionsTwintOptions.cs @@ -0,0 +1,37 @@ +// File generated from our OpenAPI spec +namespace Stripe.Checkout +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class SessionPaymentMethodOptionsTwintOptions : INestedOptions + { + /// + /// Indicates that you intend to make future payments with this PaymentIntent's payment + /// method. + /// + /// If you provide a Customer with the PaymentIntent, you can use this parameter to attach the payment method to + /// the Customer after the PaymentIntent is confirmed and the customer completes any + /// required actions. If you don't provide a Customer, you can still attach the payment method to a + /// Customer after the transaction completes. + /// + /// If the payment method is card_present and isn't a digital wallet, Stripe creates + /// and attaches a generated_card + /// payment method representing the card to the Customer instead. + /// + /// When processing card payments, Stripe uses setup_future_usage to help you comply + /// with regional legislation and network rules, such as SCA. + /// + [JsonProperty("setup_future_usage")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("setup_future_usage")] +#endif + public string SetupFutureUsage { get; set; } + } +} diff --git a/src/Stripe.net/Services/CreditNotePreviewLines/CreditNotePreviewLinesRefundOptions.cs b/src/Stripe.net/Services/CreditNotePreviewLines/CreditNotePreviewLinesRefundOptions.cs index 3af21a62bf..defbc51b76 100644 --- a/src/Stripe.net/Services/CreditNotePreviewLines/CreditNotePreviewLinesRefundOptions.cs +++ b/src/Stripe.net/Services/CreditNotePreviewLines/CreditNotePreviewLinesRefundOptions.cs @@ -18,6 +18,16 @@ public class CreditNotePreviewLinesRefundOptions : INestedOptions #endif public long? AmountRefunded { get; set; } + /// + /// The PaymentRecord refund details to link to this credit note. Required when type + /// is payment_record_refund. + /// + [JsonProperty("payment_record_refund")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_record_refund")] +#endif + public CreditNotePreviewLinesRefundPaymentRecordRefundOptions PaymentRecordRefund { get; set; } + /// /// ID of an existing refund to link this credit note to. Required when type is /// refund. @@ -27,5 +37,16 @@ public class CreditNotePreviewLinesRefundOptions : INestedOptions [STJS.JsonPropertyName("refund")] #endif public string Refund { get; set; } + + /// + /// Type of the refund, one of refund or payment_record_refund. Defaults to + /// refund. + /// One of: payment_record_refund, or refund. + /// + [JsonProperty("type")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("type")] +#endif + public string Type { get; set; } } } diff --git a/src/Stripe.net/Services/CreditNotePreviewLines/CreditNotePreviewLinesRefundPaymentRecordRefundOptions.cs b/src/Stripe.net/Services/CreditNotePreviewLines/CreditNotePreviewLinesRefundPaymentRecordRefundOptions.cs new file mode 100644 index 0000000000..789d0830fa --- /dev/null +++ b/src/Stripe.net/Services/CreditNotePreviewLines/CreditNotePreviewLinesRefundPaymentRecordRefundOptions.cs @@ -0,0 +1,31 @@ +// 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 CreditNotePreviewLinesRefundPaymentRecordRefundOptions : INestedOptions + { + /// + /// The ID of the PaymentRecord with the refund to link to this credit note. + /// + [JsonProperty("payment_record")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_record")] +#endif + public string PaymentRecord { get; set; } + + /// + /// The PaymentRecord refund group to link to this credit note. For refunds processed + /// off-Stripe, this will correspond to the processor_details.custom.refund_reference + /// field provided when reporting the refund on the PaymentRecord. + /// + [JsonProperty("refund_group")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("refund_group")] +#endif + public string RefundGroup { get; set; } + } +} diff --git a/src/Stripe.net/Services/CreditNotes/CreditNoteRefundOptions.cs b/src/Stripe.net/Services/CreditNotes/CreditNoteRefundOptions.cs index afc64717c3..1436221f7e 100644 --- a/src/Stripe.net/Services/CreditNotes/CreditNoteRefundOptions.cs +++ b/src/Stripe.net/Services/CreditNotes/CreditNoteRefundOptions.cs @@ -18,6 +18,16 @@ public class CreditNoteRefundOptions : INestedOptions #endif public long? AmountRefunded { get; set; } + /// + /// The PaymentRecord refund details to link to this credit note. Required when type + /// is payment_record_refund. + /// + [JsonProperty("payment_record_refund")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_record_refund")] +#endif + public CreditNoteRefundPaymentRecordRefundOptions PaymentRecordRefund { get; set; } + /// /// ID of an existing refund to link this credit note to. Required when type is /// refund. @@ -27,5 +37,16 @@ public class CreditNoteRefundOptions : INestedOptions [STJS.JsonPropertyName("refund")] #endif public string Refund { get; set; } + + /// + /// Type of the refund, one of refund or payment_record_refund. Defaults to + /// refund. + /// One of: payment_record_refund, or refund. + /// + [JsonProperty("type")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("type")] +#endif + public string Type { get; set; } } } diff --git a/src/Stripe.net/Services/CreditNotes/CreditNoteRefundPaymentRecordRefundOptions.cs b/src/Stripe.net/Services/CreditNotes/CreditNoteRefundPaymentRecordRefundOptions.cs new file mode 100644 index 0000000000..84d2915467 --- /dev/null +++ b/src/Stripe.net/Services/CreditNotes/CreditNoteRefundPaymentRecordRefundOptions.cs @@ -0,0 +1,31 @@ +// 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 CreditNoteRefundPaymentRecordRefundOptions : INestedOptions + { + /// + /// The ID of the PaymentRecord with the refund to link to this credit note. + /// + [JsonProperty("payment_record")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_record")] +#endif + public string PaymentRecord { get; set; } + + /// + /// The PaymentRecord refund group to link to this credit note. For refunds processed + /// off-Stripe, this will correspond to the processor_details.custom.refund_reference + /// field provided when reporting the refund on the PaymentRecord. + /// + [JsonProperty("refund_group")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("refund_group")] +#endif + public string RefundGroup { get; set; } + } +} diff --git a/src/Stripe.net/Services/CustomerPaymentMethods/CustomerPaymentMethodListOptions.cs b/src/Stripe.net/Services/CustomerPaymentMethods/CustomerPaymentMethodListOptions.cs index 0912240953..f6f1e6633e 100644 --- a/src/Stripe.net/Services/CustomerPaymentMethods/CustomerPaymentMethodListOptions.cs +++ b/src/Stripe.net/Services/CustomerPaymentMethods/CustomerPaymentMethodListOptions.cs @@ -28,10 +28,10 @@ public class CustomerPaymentMethodListOptions : ListOptions /// One of: acss_debit, affirm, afterpay_clearpay, alipay, /// alma, amazon_pay, au_becs_debit, bacs_debit, /// bancontact, billie, blik, boleto, card, - /// cashapp, crypto, customer_balance, eps, fpx, - /// giropay, gopay, grabpay, id_bank_transfer, ideal, - /// kakao_pay, klarna, konbini, kr_card, link, - /// mb_way, mobilepay, multibanco, naver_pay, + /// cashapp, crypto, custom, customer_balance, eps, + /// fpx, giropay, gopay, grabpay, id_bank_transfer, + /// ideal, kakao_pay, klarna, konbini, kr_card, + /// link, mb_way, mobilepay, multibanco, naver_pay, /// nz_bank_account, oxxo, p24, pay_by_bank, payco, /// paynow, paypal, paypay, payto, pix, promptpay, /// qris, rechnung, revolut_pay, samsung_pay, satispay, diff --git a/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsCustomerSheetFeaturesOptions.cs b/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsCustomerSheetFeaturesOptions.cs new file mode 100644 index 0000000000..cd893b8b6d --- /dev/null +++ b/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsCustomerSheetFeaturesOptions.cs @@ -0,0 +1,46 @@ +// 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 CustomerSessionComponentsCustomerSheetFeaturesOptions : INestedOptions + { + /// + /// A list of allow_redisplay + /// values that controls which saved payment methods the customer sheet displays by + /// filtering to only show payment methods with an allow_redisplay value that is + /// present in this list. + /// + /// If not specified, defaults to ["always"]. In order to display all saved payment methods, + /// specify ["always", "limited", "unspecified"]. + /// One of: always, limited, or unspecified. + /// + [JsonProperty("payment_method_allow_redisplay_filters")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_allow_redisplay_filters")] +#endif + public List PaymentMethodAllowRedisplayFilters { get; set; } + + /// + /// Controls whether the customer sheet displays the option to remove a saved payment + /// method.". + /// + /// Allowing buyers to remove their saved payment methods impacts subscriptions that depend + /// on that payment method. Removing the payment method detaches the customer + /// object from that PaymentMethod. + /// One of: disabled, or enabled. + /// + [JsonProperty("payment_method_remove")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_remove")] +#endif + public string PaymentMethodRemove { get; set; } + } +} diff --git a/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsCustomerSheetOptions.cs b/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsCustomerSheetOptions.cs new file mode 100644 index 0000000000..2da97c4ee6 --- /dev/null +++ b/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsCustomerSheetOptions.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 CustomerSessionComponentsCustomerSheetOptions : INestedOptions + { + /// + /// Whether the customer sheet is enabled. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool? Enabled { get; set; } + + /// + /// This hash defines whether the customer sheet supports certain features. + /// + [JsonProperty("features")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("features")] +#endif + public CustomerSessionComponentsCustomerSheetFeaturesOptions Features { get; set; } + } +} diff --git a/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsMobilePaymentElementFeaturesOptions.cs b/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsMobilePaymentElementFeaturesOptions.cs new file mode 100644 index 0000000000..bef8ca1644 --- /dev/null +++ b/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsMobilePaymentElementFeaturesOptions.cs @@ -0,0 +1,88 @@ +// 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 CustomerSessionComponentsMobilePaymentElementFeaturesOptions : INestedOptions + { + /// + /// A list of allow_redisplay + /// values that controls which saved payment methods the mobile payment element displays by + /// filtering to only show payment methods with an allow_redisplay value that is + /// present in this list. + /// + /// If not specified, defaults to ["always"]. In order to display all saved payment methods, + /// specify ["always", "limited", "unspecified"]. + /// One of: always, limited, or unspecified. + /// + [JsonProperty("payment_method_allow_redisplay_filters")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_allow_redisplay_filters")] +#endif + public List PaymentMethodAllowRedisplayFilters { get; set; } + + /// + /// Controls whether or not the mobile payment element shows saved payment methods. + /// One of: disabled, or enabled. + /// + [JsonProperty("payment_method_redisplay")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_redisplay")] +#endif + public string PaymentMethodRedisplay { get; set; } + + /// + /// Controls whether the mobile payment element displays the option to remove a saved + /// payment method.". + /// + /// Allowing buyers to remove their saved payment methods impacts subscriptions that depend + /// on that payment method. Removing the payment method detaches the customer + /// object from that PaymentMethod. + /// One of: disabled, or enabled. + /// + [JsonProperty("payment_method_remove")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_remove")] +#endif + public string PaymentMethodRemove { get; set; } + + /// + /// Controls whether the mobile payment element displays a checkbox offering to save a new + /// payment method. + /// + /// If a customer checks the box, the allow_redisplay + /// value on the PaymentMethod is set to 'always' at confirmation time. For + /// PaymentIntents, the setup_future_usage + /// value is also set to the value defined in payment_method_save_usage. + /// One of: disabled, or enabled. + /// + [JsonProperty("payment_method_save")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_save")] +#endif + public string PaymentMethodSave { get; set; } + + /// + /// Allows overriding the value of allow_override when saving a new payment method when + /// payment_method_save is set to disabled. Use values: "always", "limited", or + /// "unspecified". + /// + /// If not specified, defaults to nil (no override value). + /// One of: always, limited, or unspecified. + /// + [JsonProperty("payment_method_save_allow_redisplay_override")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("payment_method_save_allow_redisplay_override")] +#endif + public string PaymentMethodSaveAllowRedisplayOverride { get; set; } + } +} diff --git a/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsMobilePaymentElementOptions.cs b/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsMobilePaymentElementOptions.cs new file mode 100644 index 0000000000..e8f174046f --- /dev/null +++ b/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsMobilePaymentElementOptions.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 CustomerSessionComponentsMobilePaymentElementOptions : INestedOptions + { + /// + /// Whether the mobile payment element is enabled. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool? Enabled { get; set; } + + /// + /// This hash defines whether the mobile payment element supports certain features. + /// + [JsonProperty("features")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("features")] +#endif + public CustomerSessionComponentsMobilePaymentElementFeaturesOptions Features { get; set; } + } +} diff --git a/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsOptions.cs b/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsOptions.cs index 0d63536302..2749f60a7c 100644 --- a/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsOptions.cs +++ b/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsOptions.cs @@ -17,6 +17,24 @@ public class CustomerSessionComponentsOptions : INestedOptions #endif public CustomerSessionComponentsBuyButtonOptions BuyButton { get; set; } + /// + /// Configuration for the customer sheet. + /// + [JsonProperty("customer_sheet")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("customer_sheet")] +#endif + public CustomerSessionComponentsCustomerSheetOptions CustomerSheet { get; set; } + + /// + /// Configuration for the mobile payment element. + /// + [JsonProperty("mobile_payment_element")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("mobile_payment_element")] +#endif + public CustomerSessionComponentsMobilePaymentElementOptions MobilePaymentElement { get; set; } + /// /// Configuration for the Payment Element. /// @@ -34,5 +52,14 @@ public class CustomerSessionComponentsOptions : INestedOptions [STJS.JsonPropertyName("pricing_table")] #endif public CustomerSessionComponentsPricingTableOptions PricingTable { get; set; } + + /// + /// Configuration for the Tax ID Element. + /// + [JsonProperty("tax_id_element")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("tax_id_element")] +#endif + public CustomerSessionComponentsTaxIdElementOptions TaxIdElement { get; set; } } } diff --git a/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsTaxIdElementFeaturesOptions.cs b/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsTaxIdElementFeaturesOptions.cs new file mode 100644 index 0000000000..efa8b2bdee --- /dev/null +++ b/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsTaxIdElementFeaturesOptions.cs @@ -0,0 +1,40 @@ +// 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 CustomerSessionComponentsTaxIdElementFeaturesOptions : INestedOptions + { + /// + /// Controls whether the Tax ID Element displays saved tax IDs for the customer. This + /// parameter defaults to disabled. + /// + /// When enabled, the Tax ID Element will show existing tax IDs associated with the + /// customer, allowing them to select from previously saved tax identification numbers. + /// One of: disabled, or enabled. + /// + [JsonProperty("tax_id_redisplay")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("tax_id_redisplay")] +#endif + public string TaxIdRedisplay { get; set; } + + /// + /// Controls whether the Tax ID Element allows merchants to save new tax IDs for their + /// customer. This parameter defaults to disabled. + /// + /// When enabled, customers can enter and save new tax identification numbers during the + /// payment flow, which will be stored securely and associated with their customer object + /// for future use. + /// One of: disabled, or enabled. + /// + [JsonProperty("tax_id_save")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("tax_id_save")] +#endif + public string TaxIdSave { get; set; } + } +} diff --git a/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsTaxIdElementOptions.cs b/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsTaxIdElementOptions.cs new file mode 100644 index 0000000000..c3df90b1ab --- /dev/null +++ b/src/Stripe.net/Services/CustomerSessions/CustomerSessionComponentsTaxIdElementOptions.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 CustomerSessionComponentsTaxIdElementOptions : INestedOptions + { + /// + /// Whether the Tax ID Element is enabled. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool? Enabled { get; set; } + + /// + /// This hash defines whether the Tax ID Element supports certain features. + /// + [JsonProperty("features")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("features")] +#endif + public CustomerSessionComponentsTaxIdElementFeaturesOptions Features { get; set; } + } +} diff --git a/src/Stripe.net/Services/Files/FileCreateOptions.cs b/src/Stripe.net/Services/Files/FileCreateOptions.cs index 093dcefc53..be96d6720e 100644 --- a/src/Stripe.net/Services/Files/FileCreateOptions.cs +++ b/src/Stripe.net/Services/Files/FileCreateOptions.cs @@ -34,8 +34,8 @@ public class FileCreateOptions : BaseOptions /// One of: account_requirement, additional_verification, /// business_icon, business_logo, customer_signature, /// dispute_evidence, identity_document, issuing_regulatory_reporting, - /// pci_document, tax_document_user_upload, terminal_android_apk, or - /// terminal_reader_splashscreen. + /// pci_document, platform_terms_of_service, tax_document_user_upload, + /// terminal_android_apk, or terminal_reader_splashscreen. /// [JsonProperty("purpose")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/Files/FileListOptions.cs b/src/Stripe.net/Services/Files/FileListOptions.cs index a49253fbf2..16b89ec9a4 100644 --- a/src/Stripe.net/Services/Files/FileListOptions.cs +++ b/src/Stripe.net/Services/Files/FileListOptions.cs @@ -29,9 +29,9 @@ public class FileListOptions : ListOptions /// dispute_evidence, document_provider_identity_document, /// finance_report_run, financial_account_statement, identity_document, /// identity_document_downloadable, issuing_regulatory_reporting, - /// pci_document, selfie, sigma_scheduled_query, - /// tax_document_user_upload, terminal_android_apk, or - /// terminal_reader_splashscreen. + /// pci_document, platform_terms_of_service, selfie, + /// sigma_scheduled_query, tax_document_user_upload, + /// terminal_android_apk, or terminal_reader_splashscreen. /// [JsonProperty("purpose")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/FinancialConnections/Accounts/AccountService.cs b/src/Stripe.net/Services/FinancialConnections/Accounts/AccountService.cs index 5577a3c14f..b5894b2319 100644 --- a/src/Stripe.net/Services/FinancialConnections/Accounts/AccountService.cs +++ b/src/Stripe.net/Services/FinancialConnections/Accounts/AccountService.cs @@ -119,7 +119,8 @@ public virtual Task RefreshAsync(string id, AccountRefreshOptions optio /// ///

Subscribes to periodic refreshes of data associated with a Financial Connections - /// Account.

. + /// Account. When the account status is active, data is typically refreshed once a + /// day.

. ///
public virtual Account Subscribe(string id, AccountSubscribeOptions options = null, RequestOptions requestOptions = null) { @@ -128,7 +129,8 @@ public virtual Account Subscribe(string id, AccountSubscribeOptions options = nu /// ///

Subscribes to periodic refreshes of data associated with a Financial Connections - /// Account.

. + /// Account. When the account status is active, data is typically refreshed once a + /// day.

. ///
public virtual Task SubscribeAsync(string id, AccountSubscribeOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) { diff --git a/src/Stripe.net/Services/PaymentIntents/PaymentIntentAmountDetailsLineItemPaymentMethodOptionsKlarnaOptions.cs b/src/Stripe.net/Services/PaymentIntents/PaymentIntentAmountDetailsLineItemPaymentMethodOptionsKlarnaOptions.cs index 9ce7dfc3c8..60aea3c6ec 100644 --- a/src/Stripe.net/Services/PaymentIntents/PaymentIntentAmountDetailsLineItemPaymentMethodOptionsKlarnaOptions.cs +++ b/src/Stripe.net/Services/PaymentIntents/PaymentIntentAmountDetailsLineItemPaymentMethodOptionsKlarnaOptions.cs @@ -26,6 +26,16 @@ public class PaymentIntentAmountDetailsLineItemPaymentMethodOptionsKlarnaOptions #endif public string ProductUrl { get; set; } + /// + /// Unique reference for this line item to correlate it with your system’s internal records. + /// The field is displayed in the Klarna Consumer App if passed. + /// + [JsonProperty("reference")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("reference")] +#endif + public string Reference { get; set; } + /// /// Reference for the subscription this line item is for. /// diff --git a/src/Stripe.net/Services/PaymentLinks/PaymentLinkCreateOptions.cs b/src/Stripe.net/Services/PaymentLinks/PaymentLinkCreateOptions.cs index 7bc03e7761..b849688279 100644 --- a/src/Stripe.net/Services/PaymentLinks/PaymentLinkCreateOptions.cs +++ b/src/Stripe.net/Services/PaymentLinks/PaymentLinkCreateOptions.cs @@ -164,6 +164,15 @@ public class PaymentLinkCreateOptions : BaseOptions, IHasMetadata #endif public Dictionary Metadata { get; set; } + /// + /// Controls settings applied for collecting the customer's name. + /// + [JsonProperty("name_collection")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("name_collection")] +#endif + public PaymentLinkNameCollectionOptions NameCollection { get; set; } + /// /// The account on behalf of which to charge. /// diff --git a/src/Stripe.net/Services/PaymentLinks/PaymentLinkNameCollectionBusinessOptions.cs b/src/Stripe.net/Services/PaymentLinks/PaymentLinkNameCollectionBusinessOptions.cs new file mode 100644 index 0000000000..25d22feb68 --- /dev/null +++ b/src/Stripe.net/Services/PaymentLinks/PaymentLinkNameCollectionBusinessOptions.cs @@ -0,0 +1,30 @@ +// 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 PaymentLinkNameCollectionBusinessOptions : INestedOptions + { + /// + /// Enable business name collection on the payment link. Defaults to false. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool? Enabled { get; set; } + + /// + /// Whether the customer is required to provide their business name before checking out. + /// Defaults to false. + /// + [JsonProperty("optional")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("optional")] +#endif + public bool? Optional { get; set; } + } +} diff --git a/src/Stripe.net/Services/PaymentLinks/PaymentLinkNameCollectionIndividualOptions.cs b/src/Stripe.net/Services/PaymentLinks/PaymentLinkNameCollectionIndividualOptions.cs new file mode 100644 index 0000000000..146c92ea9c --- /dev/null +++ b/src/Stripe.net/Services/PaymentLinks/PaymentLinkNameCollectionIndividualOptions.cs @@ -0,0 +1,30 @@ +// 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 PaymentLinkNameCollectionIndividualOptions : INestedOptions + { + /// + /// Enable individual name collection on the payment link. Defaults to false. + /// + [JsonProperty("enabled")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("enabled")] +#endif + public bool? Enabled { get; set; } + + /// + /// Whether the customer is required to provide their full name before checking out. + /// Defaults to false. + /// + [JsonProperty("optional")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("optional")] +#endif + public bool? Optional { get; set; } + } +} diff --git a/src/Stripe.net/Services/PaymentLinks/PaymentLinkNameCollectionOptions.cs b/src/Stripe.net/Services/PaymentLinks/PaymentLinkNameCollectionOptions.cs new file mode 100644 index 0000000000..0863a9f1e6 --- /dev/null +++ b/src/Stripe.net/Services/PaymentLinks/PaymentLinkNameCollectionOptions.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 PaymentLinkNameCollectionOptions : INestedOptions + { + /// + /// Controls settings applied for collecting the customer's business name. + /// + [JsonProperty("business")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("business")] +#endif + public PaymentLinkNameCollectionBusinessOptions Business { get; set; } + + /// + /// Controls settings applied for collecting the customer's individual name. + /// + [JsonProperty("individual")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("individual")] +#endif + public PaymentLinkNameCollectionIndividualOptions Individual { get; set; } + } +} diff --git a/src/Stripe.net/Services/PaymentLinks/PaymentLinkUpdateOptions.cs b/src/Stripe.net/Services/PaymentLinks/PaymentLinkUpdateOptions.cs index f86755c10e..fb6b5259b8 100644 --- a/src/Stripe.net/Services/PaymentLinks/PaymentLinkUpdateOptions.cs +++ b/src/Stripe.net/Services/PaymentLinks/PaymentLinkUpdateOptions.cs @@ -131,6 +131,15 @@ public class PaymentLinkUpdateOptions : BaseOptions, IHasMetadata #endif public Dictionary Metadata { get; set; } + /// + /// Controls settings applied for collecting the customer's name. + /// + [JsonProperty("name_collection")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("name_collection")] +#endif + public PaymentLinkNameCollectionOptions NameCollection { get; set; } + /// /// A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in /// payment mode. diff --git a/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationCreateOptions.cs b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationCreateOptions.cs index fc5fc01ab5..86ae371746 100644 --- a/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationCreateOptions.cs +++ b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationCreateOptions.cs @@ -208,6 +208,17 @@ public class PaymentMethodConfigurationCreateOptions : BaseOptions #endif public PaymentMethodConfigurationCashappOptions Cashapp { get; set; } + /// + /// Stablecoin payments + /// enable customers to pay in stablecoins like USDC from 100s of wallets including Phantom + /// and Metamask. + /// + [JsonProperty("crypto")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("crypto")] +#endif + public PaymentMethodConfigurationCryptoOptions Crypto { get; set; } + /// /// Uses a customer’s cash /// balance for the payment. The cash balance can be funded via a bank transfer. Check @@ -403,6 +414,17 @@ public class PaymentMethodConfigurationCreateOptions : BaseOptions #endif public PaymentMethodConfigurationLinkOptions Link { get; set; } + /// + /// MB WAY is the most popular wallet in Portugal. After entering their phone number in your + /// checkout, customers approve the payment directly in their MB WAY app. Check this page for more details. + /// + [JsonProperty("mb_way")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("mb_way")] +#endif + public PaymentMethodConfigurationMbWayOptions MbWay { get; set; } + /// /// MobilePay is a single-use card wallet diff --git a/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationCryptoDisplayPreferenceOptions.cs b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationCryptoDisplayPreferenceOptions.cs new file mode 100644 index 0000000000..763de04134 --- /dev/null +++ b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationCryptoDisplayPreferenceOptions.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 PaymentMethodConfigurationCryptoDisplayPreferenceOptions : 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/PaymentMethodConfigurationCryptoOptions.cs b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationCryptoOptions.cs new file mode 100644 index 0000000000..d8277e8157 --- /dev/null +++ b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationCryptoOptions.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 PaymentMethodConfigurationCryptoOptions : INestedOptions + { + /// + /// Whether or not the payment method should be displayed. + /// + [JsonProperty("display_preference")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("display_preference")] +#endif + public PaymentMethodConfigurationCryptoDisplayPreferenceOptions DisplayPreference { get; set; } + } +} diff --git a/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationMbWayDisplayPreferenceOptions.cs b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationMbWayDisplayPreferenceOptions.cs new file mode 100644 index 0000000000..f6c36d7fd8 --- /dev/null +++ b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationMbWayDisplayPreferenceOptions.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 PaymentMethodConfigurationMbWayDisplayPreferenceOptions : 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/PaymentMethodConfigurationMbWayOptions.cs b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationMbWayOptions.cs new file mode 100644 index 0000000000..0178a3cb9c --- /dev/null +++ b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationMbWayOptions.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 PaymentMethodConfigurationMbWayOptions : INestedOptions + { + /// + /// Whether or not the payment method should be displayed. + /// + [JsonProperty("display_preference")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("display_preference")] +#endif + public PaymentMethodConfigurationMbWayDisplayPreferenceOptions DisplayPreference { get; set; } + } +} diff --git a/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationUpdateOptions.cs b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationUpdateOptions.cs index a8098b3368..a1651f2c87 100644 --- a/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationUpdateOptions.cs +++ b/src/Stripe.net/Services/PaymentMethodConfigurations/PaymentMethodConfigurationUpdateOptions.cs @@ -217,6 +217,17 @@ public class PaymentMethodConfigurationUpdateOptions : BaseOptions #endif public PaymentMethodConfigurationCashappOptions Cashapp { get; set; } + /// + /// Stablecoin payments + /// enable customers to pay in stablecoins like USDC from 100s of wallets including Phantom + /// and Metamask. + /// + [JsonProperty("crypto")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("crypto")] +#endif + public PaymentMethodConfigurationCryptoOptions Crypto { get; set; } + /// /// Uses a customer’s cash /// balance for the payment. The cash balance can be funded via a bank transfer. Check @@ -412,6 +423,17 @@ public class PaymentMethodConfigurationUpdateOptions : BaseOptions #endif public PaymentMethodConfigurationLinkOptions Link { get; set; } + /// + /// MB WAY is the most popular wallet in Portugal. After entering their phone number in your + /// checkout, customers approve the payment directly in their MB WAY app. Check this page for more details. + /// + [JsonProperty("mb_way")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("mb_way")] +#endif + public PaymentMethodConfigurationMbWayOptions MbWay { get; set; } + /// /// MobilePay is a single-use card wallet diff --git a/src/Stripe.net/Services/PaymentMethods/PaymentMethodCreateOptions.cs b/src/Stripe.net/Services/PaymentMethods/PaymentMethodCreateOptions.cs index 6a9f63b2ee..0e1c335344 100644 --- a/src/Stripe.net/Services/PaymentMethods/PaymentMethodCreateOptions.cs +++ b/src/Stripe.net/Services/PaymentMethods/PaymentMethodCreateOptions.cs @@ -187,6 +187,16 @@ public class PaymentMethodCreateOptions : BaseOptions, IHasMetadata #endif public PaymentMethodCryptoOptions Crypto { get; set; } + /// + /// If this is a custom PaymentMethod, this hash contains details about the Custom + /// payment method. + /// + [JsonProperty("custom")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("custom")] +#endif + public PaymentMethodCustomOptions Custom { get; set; } + /// /// The Customer to whom the original PaymentMethod is attached. /// @@ -634,10 +644,10 @@ public class PaymentMethodCreateOptions : BaseOptions, IHasMetadata /// One of: acss_debit, affirm, afterpay_clearpay, alipay, /// alma, amazon_pay, au_becs_debit, bacs_debit, /// bancontact, billie, blik, boleto, card, - /// cashapp, crypto, customer_balance, eps, fpx, - /// giropay, gopay, grabpay, id_bank_transfer, ideal, - /// kakao_pay, klarna, konbini, kr_card, link, - /// mb_way, mobilepay, multibanco, naver_pay, + /// cashapp, crypto, custom, customer_balance, eps, + /// fpx, giropay, gopay, grabpay, id_bank_transfer, + /// ideal, kakao_pay, klarna, konbini, kr_card, + /// link, mb_way, mobilepay, multibanco, naver_pay, /// nz_bank_account, oxxo, p24, pay_by_bank, payco, /// paynow, paypal, paypay, payto, pix, promptpay, /// qris, rechnung, revolut_pay, samsung_pay, satispay, diff --git a/src/Stripe.net/Services/PaymentMethods/PaymentMethodCustomOptions.cs b/src/Stripe.net/Services/PaymentMethods/PaymentMethodCustomOptions.cs new file mode 100644 index 0000000000..d00a4c5d95 --- /dev/null +++ b/src/Stripe.net/Services/PaymentMethods/PaymentMethodCustomOptions.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 PaymentMethodCustomOptions : INestedOptions + { + /// + /// ID of the Dashboard-only CustomPaymentMethodType. This field is used by Stripe products' + /// internal code to support CPMs. + /// + [JsonProperty("type")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("type")] +#endif + public string Type { get; set; } + } +} diff --git a/src/Stripe.net/Services/PaymentMethods/PaymentMethodListOptions.cs b/src/Stripe.net/Services/PaymentMethods/PaymentMethodListOptions.cs index ab43a9c605..c3c0ad0abf 100644 --- a/src/Stripe.net/Services/PaymentMethods/PaymentMethodListOptions.cs +++ b/src/Stripe.net/Services/PaymentMethods/PaymentMethodListOptions.cs @@ -18,17 +18,17 @@ public class PaymentMethodListOptions : ListOptions public string Customer { get; set; } /// - /// An optional filter on the list, based on the object type field. Without the - /// filter, the list includes all current and future payment method types. If your - /// integration expects only one type of payment method in the response, make sure to - /// provide a type value in the request. + /// Filters the list by the object type field. Unfiltered, the list returns all + /// payment method types except custom. If your integration expects only one type of + /// payment method in the response, specify that type value in the request to reduce your + /// payload. /// One of: acss_debit, affirm, afterpay_clearpay, alipay, /// alma, amazon_pay, au_becs_debit, bacs_debit, /// bancontact, billie, blik, boleto, card, - /// cashapp, crypto, customer_balance, eps, fpx, - /// giropay, gopay, grabpay, id_bank_transfer, ideal, - /// kakao_pay, klarna, konbini, kr_card, link, - /// mb_way, mobilepay, multibanco, naver_pay, + /// cashapp, crypto, custom, customer_balance, eps, + /// fpx, giropay, gopay, grabpay, id_bank_transfer, + /// ideal, kakao_pay, klarna, konbini, kr_card, + /// link, mb_way, mobilepay, multibanco, naver_pay, /// nz_bank_account, oxxo, p24, pay_by_bank, payco, /// paynow, paypal, paypay, payto, pix, promptpay, /// qris, rechnung, revolut_pay, samsung_pay, satispay, diff --git a/src/Stripe.net/Services/PaymentRecords/PaymentRecordAmountOptions.cs b/src/Stripe.net/Services/PaymentRecords/PaymentRecordAmountOptions.cs new file mode 100644 index 0000000000..40498c8f74 --- /dev/null +++ b/src/Stripe.net/Services/PaymentRecords/PaymentRecordAmountOptions.cs @@ -0,0 +1,33 @@ +// 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 PaymentRecordAmountOptions : INestedOptions + { + /// + /// Three-letter ISO currency + /// code, in lowercase. Must be a supported + /// currency. + /// + [JsonProperty("currency")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("currency")] +#endif + public string Currency { get; set; } + + /// + /// A positive integer representing the amount in the currency's minor unit. For example, + /// 100 can represent 1 USD or 100 JPY. + /// + [JsonProperty("value")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("value")] +#endif + public long? Value { get; set; } + } +} diff --git a/src/Stripe.net/Services/PaymentRecords/PaymentRecordProcessorDetailsCustomOptions.cs b/src/Stripe.net/Services/PaymentRecords/PaymentRecordProcessorDetailsCustomOptions.cs index f7d790b6e1..d742cc79c2 100644 --- a/src/Stripe.net/Services/PaymentRecords/PaymentRecordProcessorDetailsCustomOptions.cs +++ b/src/Stripe.net/Services/PaymentRecords/PaymentRecordProcessorDetailsCustomOptions.cs @@ -17,5 +17,14 @@ public class PaymentRecordProcessorDetailsCustomOptions : INestedOptions [STJS.JsonPropertyName("payment_reference")] #endif public string PaymentReference { get; set; } + + /// + /// A reference to the external refund. This field must be unique across all refunds. + /// + [JsonProperty("refund_reference")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("refund_reference")] +#endif + public string RefundReference { get; set; } } } diff --git a/src/Stripe.net/Services/PaymentRecords/PaymentRecordRefundedOptions.cs b/src/Stripe.net/Services/PaymentRecords/PaymentRecordRefundedOptions.cs new file mode 100644 index 0000000000..3b644dc845 --- /dev/null +++ b/src/Stripe.net/Services/PaymentRecords/PaymentRecordRefundedOptions.cs @@ -0,0 +1,24 @@ +// 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 PaymentRecordRefundedOptions : INestedOptions + { + /// + /// When the reported refund completed. Measured in seconds since the Unix epoch. + /// + [JsonProperty("refunded_at")] + [JsonConverter(typeof(UnixDateTimeConverter))] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("refunded_at")] + [STJS.JsonConverter(typeof(STJUnixDateTimeConverter))] +#endif + public DateTime? RefundedAt { get; set; } + } +} diff --git a/src/Stripe.net/Services/PaymentRecords/PaymentRecordReportRefundOptions.cs b/src/Stripe.net/Services/PaymentRecords/PaymentRecordReportRefundOptions.cs new file mode 100644 index 0000000000..905aa3aa2e --- /dev/null +++ b/src/Stripe.net/Services/PaymentRecords/PaymentRecordReportRefundOptions.cs @@ -0,0 +1,76 @@ +// File generated from our OpenAPI spec +namespace Stripe +{ + using System; + using System.Collections.Generic; + using Newtonsoft.Json; + using Stripe.Infrastructure; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class PaymentRecordReportRefundOptions : BaseOptions, IHasMetadata + { + /// + /// A positive integer in the smallest currency unit + /// representing how much of this payment to refund. Can refund only up to the remaining, + /// unrefunded amount of the payment. + /// + [JsonProperty("amount")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("amount")] +#endif + public PaymentRecordAmountOptions Amount { get; set; } + + /// + /// When the reported refund was initiated. Measured in seconds since the Unix epoch. + /// + [JsonProperty("initiated_at")] + [JsonConverter(typeof(UnixDateTimeConverter))] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("initiated_at")] + [STJS.JsonConverter(typeof(STJUnixDateTimeConverter))] +#endif + public DateTime? InitiatedAt { get; set; } + + /// + /// Set of key-value pairs that you can + /// attach to an object. This can be useful for storing additional information about the + /// object in a structured format. Individual keys can be unset by posting an empty value to + /// them. All keys can be unset by posting an empty value to metadata. + /// + [JsonProperty("metadata")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("metadata")] +#endif + public Dictionary Metadata { get; set; } + + /// + /// The outcome of the reported refund. + /// + [JsonProperty("outcome")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("outcome")] +#endif + public string Outcome { get; set; } + + /// + /// Processor information for this refund. + /// + [JsonProperty("processor_details")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("processor_details")] +#endif + public PaymentRecordProcessorDetailsOptions ProcessorDetails { get; set; } + + /// + /// Information about the payment attempt refund. + /// + [JsonProperty("refunded")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("refunded")] +#endif + public PaymentRecordRefundedOptions Refunded { get; set; } + } +} diff --git a/src/Stripe.net/Services/PaymentRecords/PaymentRecordService.cs b/src/Stripe.net/Services/PaymentRecords/PaymentRecordService.cs index 3ac03f9d04..40ec2ab842 100644 --- a/src/Stripe.net/Services/PaymentRecords/PaymentRecordService.cs +++ b/src/Stripe.net/Services/PaymentRecords/PaymentRecordService.cs @@ -147,5 +147,23 @@ public virtual Task ReportPaymentAttemptInformationalAsync(string { return this.RequestAsync(BaseAddress.Api, HttpMethod.Post, $"/v1/payment_records/{WebUtility.UrlEncode(id)}/report_payment_attempt_informational", options, requestOptions, cancellationToken); } + + /// + ///

Report that the most recent payment attempt on the specified Payment Record was + /// refunded.

. + ///
+ public virtual PaymentRecord ReportRefund(string id, PaymentRecordReportRefundOptions options = null, RequestOptions requestOptions = null) + { + return this.Request(BaseAddress.Api, HttpMethod.Post, $"/v1/payment_records/{WebUtility.UrlEncode(id)}/report_refund", options, requestOptions); + } + + /// + ///

Report that the most recent payment attempt on the specified Payment Record was + /// refunded.

. + ///
+ public virtual Task ReportRefundAsync(string id, PaymentRecordReportRefundOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) + { + return this.RequestAsync(BaseAddress.Api, HttpMethod.Post, $"/v1/payment_records/{WebUtility.UrlEncode(id)}/report_refund", options, requestOptions, cancellationToken); + } } } diff --git a/src/Stripe.net/Services/Payouts/PayoutService.cs b/src/Stripe.net/Services/Payouts/PayoutService.cs index 647c2d50e8..9b75d58ca6 100644 --- a/src/Stripe.net/Services/Payouts/PayoutService.cs +++ b/src/Stripe.net/Services/Payouts/PayoutService.cs @@ -146,8 +146,9 @@ public virtual IAsyncEnumerable ListAutoPagingAsync(PayoutListOptions op /// ///

Reverses a payout by debiting the destination bank account. At this time, you can - /// only reverse payouts for connected accounts to US bank accounts. If the payout is manual - /// and in the pending status, use /v1/payouts/:id/cancel instead.

. + /// only reverse payouts for connected accounts to US and Canadian bank accounts. If the + /// payout is manual and in the pending status, use /v1/payouts/:id/cancel + /// instead.

. /// ///

By requesting a reversal through /v1/payouts/:id/reverse, you confirm that the /// authorized signatory of the selected bank account authorizes the debit on the bank @@ -160,8 +161,9 @@ public virtual Payout Reverse(string id, PayoutReverseOptions options = null, Re ///

///

Reverses a payout by debiting the destination bank account. At this time, you can - /// only reverse payouts for connected accounts to US bank accounts. If the payout is manual - /// and in the pending status, use /v1/payouts/:id/cancel instead.

. + /// only reverse payouts for connected accounts to US and Canadian bank accounts. If the + /// payout is manual and in the pending status, use /v1/payouts/:id/cancel + /// instead.

. /// ///

By requesting a reversal through /v1/payouts/:id/reverse, you confirm that the /// authorized signatory of the selected bank account authorizes the debit on the bank diff --git a/src/Stripe.net/Services/SetupIntents/SetupIntentCreateOptions.cs b/src/Stripe.net/Services/SetupIntents/SetupIntentCreateOptions.cs index 6fc6752992..7b604c2f95 100644 --- a/src/Stripe.net/Services/SetupIntents/SetupIntentCreateOptions.cs +++ b/src/Stripe.net/Services/SetupIntents/SetupIntentCreateOptions.cs @@ -93,6 +93,27 @@ public class SetupIntentCreateOptions : BaseOptions, IHasMetadata #endif public string Description { get; set; } + ///

+ /// The list of payment method types to exclude from use with this SetupIntent. + /// One of: acss_debit, affirm, afterpay_clearpay, alipay, + /// alma, amazon_pay, au_becs_debit, bacs_debit, + /// bancontact, billie, blik, boleto, card, + /// cashapp, crypto, customer_balance, eps, fpx, + /// giropay, gopay, grabpay, id_bank_transfer, ideal, + /// kakao_pay, klarna, konbini, kr_card, mb_way, + /// mobilepay, multibanco, naver_pay, nz_bank_account, + /// oxxo, p24, pay_by_bank, payco, paynow, paypal, + /// paypay, payto, pix, promptpay, qris, rechnung, + /// revolut_pay, samsung_pay, satispay, sepa_debit, + /// shopeepay, sofort, stripe_balance, swish, twint, + /// us_bank_account, wechat_pay, or zip. + /// + [JsonProperty("excluded_payment_method_types")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("excluded_payment_method_types")] +#endif + public List ExcludedPaymentMethodTypes { get; set; } + /// /// Indicates the directions of money movement for which this payment method is intended to /// be used. diff --git a/src/Stripe.net/Services/SetupIntents/SetupIntentUpdateOptions.cs b/src/Stripe.net/Services/SetupIntents/SetupIntentUpdateOptions.cs index b78b36119d..1cc0f7d30b 100644 --- a/src/Stripe.net/Services/SetupIntents/SetupIntentUpdateOptions.cs +++ b/src/Stripe.net/Services/SetupIntents/SetupIntentUpdateOptions.cs @@ -59,6 +59,27 @@ public class SetupIntentUpdateOptions : BaseOptions, IHasMetadata #endif public string Description { get; set; } + /// + /// The list of payment method types to exclude from use with this SetupIntent. + /// One of: acss_debit, affirm, afterpay_clearpay, alipay, + /// alma, amazon_pay, au_becs_debit, bacs_debit, + /// bancontact, billie, blik, boleto, card, + /// cashapp, crypto, customer_balance, eps, fpx, + /// giropay, gopay, grabpay, id_bank_transfer, ideal, + /// kakao_pay, klarna, konbini, kr_card, mb_way, + /// mobilepay, multibanco, naver_pay, nz_bank_account, + /// oxxo, p24, pay_by_bank, payco, paynow, paypal, + /// paypay, payto, pix, promptpay, qris, rechnung, + /// revolut_pay, samsung_pay, satispay, sepa_debit, + /// shopeepay, sofort, stripe_balance, swish, twint, + /// us_bank_account, wechat_pay, or zip. + /// + [JsonProperty("excluded_payment_method_types")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("excluded_payment_method_types")] +#endif + public List ExcludedPaymentMethodTypes { get; set; } + /// /// Indicates the directions of money movement for which this payment method is intended to /// be used. diff --git a/src/Stripe.net/Services/Tax/Registrations/RegistrationCountryOptionsOptions.cs b/src/Stripe.net/Services/Tax/Registrations/RegistrationCountryOptionsOptions.cs index 9087eaf07b..63143a47f0 100644 --- a/src/Stripe.net/Services/Tax/Registrations/RegistrationCountryOptionsOptions.cs +++ b/src/Stripe.net/Services/Tax/Registrations/RegistrationCountryOptionsOptions.cs @@ -809,6 +809,15 @@ public class RegistrationCountryOptionsOptions : INestedOptions #endif public RegistrationCountryOptionsTrOptions Tr { get; set; } + /// + /// Options for the registration in TW. + /// + [JsonProperty("tw")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("tw")] +#endif + public RegistrationCountryOptionsTwOptions Tw { get; set; } + /// /// Options for the registration in TZ. /// diff --git a/src/Stripe.net/Services/Tax/Registrations/RegistrationCountryOptionsTwOptions.cs b/src/Stripe.net/Services/Tax/Registrations/RegistrationCountryOptionsTwOptions.cs new file mode 100644 index 0000000000..9d813b6cf4 --- /dev/null +++ b/src/Stripe.net/Services/Tax/Registrations/RegistrationCountryOptionsTwOptions.cs @@ -0,0 +1,20 @@ +// File generated from our OpenAPI spec +namespace Stripe.Tax +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class RegistrationCountryOptionsTwOptions : INestedOptions + { + /// + /// Type of registration to be created in country. + /// + [JsonProperty("type")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("type")] +#endif + public string Type { get; set; } + } +} diff --git a/src/Stripe.net/Services/Terminal/Configurations/ConfigurationTippingGipOptions.cs b/src/Stripe.net/Services/Terminal/Configurations/ConfigurationTippingGipOptions.cs new file mode 100644 index 0000000000..2430945757 --- /dev/null +++ b/src/Stripe.net/Services/Terminal/Configurations/ConfigurationTippingGipOptions.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 ConfigurationTippingGipOptions : 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 53cb82efed..ef1ddecdaa 100644 --- a/src/Stripe.net/Services/Terminal/Configurations/ConfigurationTippingOptions.cs +++ b/src/Stripe.net/Services/Terminal/Configurations/ConfigurationTippingOptions.cs @@ -89,6 +89,15 @@ public class ConfigurationTippingOptions : INestedOptions #endif public ConfigurationTippingGbpOptions Gbp { get; set; } + /// + /// Tipping configuration for GIP. + /// + [JsonProperty("gip")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("gip")] +#endif + public ConfigurationTippingGipOptions Gip { get; set; } + /// /// Tipping configuration for HKD. /// diff --git a/src/Stripe.net/Services/Terminal/Readers/ReaderCartLineItemOptions.cs b/src/Stripe.net/Services/Terminal/Readers/ReaderCartLineItemOptions.cs index 707ec45616..7788411dc6 100644 --- a/src/Stripe.net/Services/Terminal/Readers/ReaderCartLineItemOptions.cs +++ b/src/Stripe.net/Services/Terminal/Readers/ReaderCartLineItemOptions.cs @@ -9,7 +9,8 @@ namespace Stripe.Terminal public class ReaderCartLineItemOptions : INestedOptions { /// - /// The price of the item in cents. + /// The price of the item in the smallest currency unit. /// [JsonProperty("amount")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/Terminal/Readers/ReaderCartOptions.cs b/src/Stripe.net/Services/Terminal/Readers/ReaderCartOptions.cs index 6bbc865064..8d12dda56c 100644 --- a/src/Stripe.net/Services/Terminal/Readers/ReaderCartOptions.cs +++ b/src/Stripe.net/Services/Terminal/Readers/ReaderCartOptions.cs @@ -21,7 +21,7 @@ public class ReaderCartOptions : INestedOptions public string Currency { get; set; } /// - /// Array of line items that were purchased. + /// Array of line items to display. /// [JsonProperty("line_items")] #if NET6_0_OR_GREATER @@ -30,7 +30,8 @@ public class ReaderCartOptions : INestedOptions public List LineItems { get; set; } /// - /// The amount of tax in cents. + /// The amount of tax in the smallest currency unit. /// [JsonProperty("tax")] #if NET6_0_OR_GREATER @@ -39,7 +40,8 @@ public class ReaderCartOptions : INestedOptions public long? Tax { get; set; } /// - /// Total balance of cart due in cents. + /// Total balance of cart due in the smallest currency unit. /// [JsonProperty("total")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/Terminal/Readers/ReaderCollectInputsOptions.cs b/src/Stripe.net/Services/Terminal/Readers/ReaderCollectInputsOptions.cs index 41434d3776..2ef86947ed 100644 --- a/src/Stripe.net/Services/Terminal/Readers/ReaderCollectInputsOptions.cs +++ b/src/Stripe.net/Services/Terminal/Readers/ReaderCollectInputsOptions.cs @@ -10,7 +10,7 @@ namespace Stripe.Terminal public class ReaderCollectInputsOptions : BaseOptions, IHasMetadata { /// - /// List of inputs to be collected using the Reader. + /// List of inputs to be collected from the customer using the Reader. Maximum 5 inputs. /// [JsonProperty("inputs")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/Terminal/Readers/ReaderCollectPaymentMethodOptions.cs b/src/Stripe.net/Services/Terminal/Readers/ReaderCollectPaymentMethodOptions.cs index 15f5a87b38..f286b4e5d9 100644 --- a/src/Stripe.net/Services/Terminal/Readers/ReaderCollectPaymentMethodOptions.cs +++ b/src/Stripe.net/Services/Terminal/Readers/ReaderCollectPaymentMethodOptions.cs @@ -9,7 +9,8 @@ namespace Stripe.Terminal public class ReaderCollectPaymentMethodOptions : BaseOptions { /// - /// Configuration overrides. + /// Configuration overrides for this collection, such as tipping, surcharging, and customer + /// cancellation settings. /// [JsonProperty("collect_config")] #if NET6_0_OR_GREATER @@ -18,7 +19,7 @@ public class ReaderCollectPaymentMethodOptions : BaseOptions public ReaderCollectConfigOptions CollectConfig { get; set; } /// - /// PaymentIntent ID. + /// The ID of the PaymentIntent to collect a payment method for. /// [JsonProperty("payment_intent")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/Terminal/Readers/ReaderConfirmPaymentIntentOptions.cs b/src/Stripe.net/Services/Terminal/Readers/ReaderConfirmPaymentIntentOptions.cs index 4dace8691e..1d0e00b116 100644 --- a/src/Stripe.net/Services/Terminal/Readers/ReaderConfirmPaymentIntentOptions.cs +++ b/src/Stripe.net/Services/Terminal/Readers/ReaderConfirmPaymentIntentOptions.cs @@ -9,7 +9,8 @@ namespace Stripe.Terminal public class ReaderConfirmPaymentIntentOptions : BaseOptions { /// - /// Configuration overrides. + /// Configuration overrides for this confirmation, such as surcharge settings and return + /// URL. /// [JsonProperty("confirm_config")] #if NET6_0_OR_GREATER @@ -18,7 +19,7 @@ public class ReaderConfirmPaymentIntentOptions : BaseOptions public ReaderConfirmConfigOptions ConfirmConfig { get; set; } /// - /// PaymentIntent ID. + /// The ID of the PaymentIntent to confirm. /// [JsonProperty("payment_intent")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/Terminal/Readers/ReaderInputCustomTextOptions.cs b/src/Stripe.net/Services/Terminal/Readers/ReaderInputCustomTextOptions.cs index abbc331ac4..f7592aa907 100644 --- a/src/Stripe.net/Services/Terminal/Readers/ReaderInputCustomTextOptions.cs +++ b/src/Stripe.net/Services/Terminal/Readers/ReaderInputCustomTextOptions.cs @@ -18,7 +18,7 @@ public class ReaderInputCustomTextOptions : INestedOptions public string Description { get; set; } /// - /// The skip button text. + /// Custom text for the skip button. Maximum 14 characters. /// [JsonProperty("skip_button")] #if NET6_0_OR_GREATER @@ -27,7 +27,7 @@ public class ReaderInputCustomTextOptions : INestedOptions public string SkipButton { get; set; } /// - /// The submit button text. + /// Custom text for the submit button. Maximum 30 characters. /// [JsonProperty("submit_button")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/Terminal/Readers/ReaderInputSelectionChoiceOptions.cs b/src/Stripe.net/Services/Terminal/Readers/ReaderInputSelectionChoiceOptions.cs index 6517aa2602..c3f64e9208 100644 --- a/src/Stripe.net/Services/Terminal/Readers/ReaderInputSelectionChoiceOptions.cs +++ b/src/Stripe.net/Services/Terminal/Readers/ReaderInputSelectionChoiceOptions.cs @@ -18,7 +18,8 @@ public class ReaderInputSelectionChoiceOptions : INestedOptions, IHasId public string Id { get; set; } /// - /// The style of the button which will be shown for this choice. + /// The style of the button which will be shown for this choice. Can be primary or + /// secondary. /// One of: primary, or secondary. /// [JsonProperty("style")] diff --git a/src/Stripe.net/Services/Terminal/Readers/ReaderInputToggleOptions.cs b/src/Stripe.net/Services/Terminal/Readers/ReaderInputToggleOptions.cs index 2c819df31d..45bfe67d1f 100644 --- a/src/Stripe.net/Services/Terminal/Readers/ReaderInputToggleOptions.cs +++ b/src/Stripe.net/Services/Terminal/Readers/ReaderInputToggleOptions.cs @@ -9,7 +9,7 @@ namespace Stripe.Terminal public class ReaderInputToggleOptions : INestedOptions { /// - /// The default value of the toggle. + /// The default value of the toggle. Can be enabled or disabled. /// One of: disabled, or enabled. /// [JsonProperty("default_value")] @@ -19,7 +19,8 @@ public class ReaderInputToggleOptions : INestedOptions public string DefaultValue { get; set; } /// - /// The description which will be displayed for the toggle. + /// The description which will be displayed for the toggle. Maximum 50 characters. At least + /// one of title or description must be provided. /// [JsonProperty("description")] #if NET6_0_OR_GREATER @@ -28,7 +29,8 @@ public class ReaderInputToggleOptions : INestedOptions public string Description { get; set; } /// - /// The title which will be displayed for the toggle. + /// The title which will be displayed for the toggle. Maximum 50 characters. At least one of + /// title or description must be provided. /// [JsonProperty("title")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/Terminal/Readers/ReaderProcessPaymentIntentOptions.cs b/src/Stripe.net/Services/Terminal/Readers/ReaderProcessPaymentIntentOptions.cs index 02d62fc787..ef450ab3a1 100644 --- a/src/Stripe.net/Services/Terminal/Readers/ReaderProcessPaymentIntentOptions.cs +++ b/src/Stripe.net/Services/Terminal/Readers/ReaderProcessPaymentIntentOptions.cs @@ -9,7 +9,7 @@ namespace Stripe.Terminal public class ReaderProcessPaymentIntentOptions : BaseOptions { /// - /// PaymentIntent ID. + /// The ID of the PaymentIntent to process on the reader. /// [JsonProperty("payment_intent")] #if NET6_0_OR_GREATER @@ -18,7 +18,8 @@ public class ReaderProcessPaymentIntentOptions : BaseOptions public string PaymentIntent { get; set; } /// - /// Configuration overrides. + /// Configuration overrides for this transaction, such as tipping and customer cancellation + /// settings. /// [JsonProperty("process_config")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/Terminal/Readers/ReaderProcessSetupIntentOptions.cs b/src/Stripe.net/Services/Terminal/Readers/ReaderProcessSetupIntentOptions.cs index 9ee775e098..fc3e8419a1 100644 --- a/src/Stripe.net/Services/Terminal/Readers/ReaderProcessSetupIntentOptions.cs +++ b/src/Stripe.net/Services/Terminal/Readers/ReaderProcessSetupIntentOptions.cs @@ -21,7 +21,7 @@ public class ReaderProcessSetupIntentOptions : BaseOptions public string AllowRedisplay { get; set; } /// - /// Configuration overrides. + /// Configuration overrides for this setup, such as MOTO and customer cancellation settings. /// [JsonProperty("process_config")] #if NET6_0_OR_GREATER @@ -30,7 +30,7 @@ public class ReaderProcessSetupIntentOptions : BaseOptions public ReaderProcessConfigOptions ProcessConfig { get; set; } /// - /// SetupIntent ID. + /// The ID of the SetupIntent to process on the reader. /// [JsonProperty("setup_intent")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/Terminal/Readers/ReaderRefundPaymentOptions.cs b/src/Stripe.net/Services/Terminal/Readers/ReaderRefundPaymentOptions.cs index 4b5c25cf0e..858e8b9b03 100644 --- a/src/Stripe.net/Services/Terminal/Readers/ReaderRefundPaymentOptions.cs +++ b/src/Stripe.net/Services/Terminal/Readers/ReaderRefundPaymentOptions.cs @@ -63,7 +63,7 @@ public class ReaderRefundPaymentOptions : BaseOptions, IHasMetadata public bool? RefundApplicationFee { get; set; } /// - /// Configuration overrides. + /// Configuration overrides for this refund, such as customer cancellation settings. /// [JsonProperty("refund_payment_config")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/Terminal/Readers/ReaderService.cs b/src/Stripe.net/Services/Terminal/Readers/ReaderService.cs index 5c55c1463f..4073d3c016 100644 --- a/src/Stripe.net/Services/Terminal/Readers/ReaderService.cs +++ b/src/Stripe.net/Services/Terminal/Readers/ReaderService.cs @@ -30,7 +30,9 @@ public ReaderService(IStripeClient client) } /// - ///

Cancels the current reader action.

. + ///

Cancels the current reader action. See Programmatic + /// Cancellation for more details.

. ///
public virtual Reader CancelAction(string id, ReaderCancelActionOptions options = null, RequestOptions requestOptions = null) { @@ -38,7 +40,9 @@ public virtual Reader CancelAction(string id, ReaderCancelActionOptions options } /// - ///

Cancels the current reader action.

. + ///

Cancels the current reader action. See Programmatic + /// Cancellation for more details.

. ///
public virtual Task CancelActionAsync(string id, ReaderCancelActionOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) { @@ -46,7 +50,9 @@ public virtual Task CancelActionAsync(string id, ReaderCancelActionOptio } /// - ///

Initiates an input collection flow on a Reader.

. + ///

Initiates an input + /// collection flow on a Reader to display input forms and collect information from your + /// customers.

. ///
public virtual Reader CollectInputs(string id, ReaderCollectInputsOptions options = null, RequestOptions requestOptions = null) { @@ -54,7 +60,9 @@ public virtual Reader CollectInputs(string id, ReaderCollectInputsOptions option } /// - ///

Initiates an input collection flow on a Reader.

. + ///

Initiates an input + /// collection flow on a Reader to display input forms and collect information from your + /// customers.

. ///
public virtual Task CollectInputsAsync(string id, ReaderCollectInputsOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) { @@ -63,7 +71,9 @@ public virtual Task CollectInputsAsync(string id, ReaderCollectInputsOpt /// ///

Initiates a payment flow on a Reader and updates the PaymentIntent with card details - /// before manual confirmation.

. + /// before manual confirmation. See Collecting + /// a Payment method for more details.

. ///
public virtual Reader CollectPaymentMethod(string id, ReaderCollectPaymentMethodOptions options = null, RequestOptions requestOptions = null) { @@ -72,7 +82,9 @@ public virtual Reader CollectPaymentMethod(string id, ReaderCollectPaymentMethod /// ///

Initiates a payment flow on a Reader and updates the PaymentIntent with card details - /// before manual confirmation.

. + /// before manual confirmation. See Collecting + /// a Payment method for more details.

. ///
public virtual Task CollectPaymentMethodAsync(string id, ReaderCollectPaymentMethodOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) { @@ -80,7 +92,9 @@ public virtual Task CollectPaymentMethodAsync(string id, ReaderCollectPa } /// - ///

Finalizes a payment on a Reader.

. + ///

Finalizes a payment on a Reader. See Confirming + /// a Payment for more details.

. ///
public virtual Reader ConfirmPaymentIntent(string id, ReaderConfirmPaymentIntentOptions options = null, RequestOptions requestOptions = null) { @@ -88,7 +102,9 @@ public virtual Reader ConfirmPaymentIntent(string id, ReaderConfirmPaymentIntent } /// - ///

Finalizes a payment on a Reader.

. + ///

Finalizes a payment on a Reader. See Confirming + /// a Payment for more details.

. ///
public virtual Task ConfirmPaymentIntentAsync(string id, ReaderConfirmPaymentIntentOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) { @@ -176,7 +192,9 @@ public virtual IAsyncEnumerable ListAutoPagingAsync(ReaderListOptions op } /// - ///

Initiates a payment flow on a Reader.

. + ///

Initiates a payment flow on a Reader. See process + /// the payment for more details.

. ///
public virtual Reader ProcessPaymentIntent(string id, ReaderProcessPaymentIntentOptions options = null, RequestOptions requestOptions = null) { @@ -184,7 +202,9 @@ public virtual Reader ProcessPaymentIntent(string id, ReaderProcessPaymentIntent } /// - ///

Initiates a payment flow on a Reader.

. + ///

Initiates a payment flow on a Reader. See process + /// the payment for more details.

. ///
public virtual Task ProcessPaymentIntentAsync(string id, ReaderProcessPaymentIntentOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) { @@ -192,7 +212,9 @@ public virtual Task ProcessPaymentIntentAsync(string id, ReaderProcessPa } /// - ///

Initiates a setup intent flow on a Reader.

. + ///

Initiates a SetupIntent flow on a Reader. See Save + /// directly without charging for more details.

. ///
public virtual Reader ProcessSetupIntent(string id, ReaderProcessSetupIntentOptions options = null, RequestOptions requestOptions = null) { @@ -200,7 +222,9 @@ public virtual Reader ProcessSetupIntent(string id, ReaderProcessSetupIntentOpti } /// - ///

Initiates a setup intent flow on a Reader.

. + ///

Initiates a SetupIntent flow on a Reader. See Save + /// directly without charging for more details.

. ///
public virtual Task ProcessSetupIntentAsync(string id, ReaderProcessSetupIntentOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) { @@ -208,7 +232,9 @@ public virtual Task ProcessSetupIntentAsync(string id, ReaderProcessSetu } /// - ///

Initiates a refund on a Reader

. + ///

Initiates an in-person refund on a Reader. See Refund + /// an Interac Payment for more details.

. ///
public virtual Reader RefundPayment(string id, ReaderRefundPaymentOptions options = null, RequestOptions requestOptions = null) { @@ -216,7 +242,9 @@ public virtual Reader RefundPayment(string id, ReaderRefundPaymentOptions option } /// - ///

Initiates a refund on a Reader

. + ///

Initiates an in-person refund on a Reader. See Refund + /// an Interac Payment for more details.

. ///
public virtual Task RefundPaymentAsync(string id, ReaderRefundPaymentOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) { @@ -224,7 +252,8 @@ public virtual Task RefundPaymentAsync(string id, ReaderRefundPaymentOpt } /// - ///

Sets reader display to show cart details.

. + ///

Sets the reader display to show cart details.

. ///
public virtual Reader SetReaderDisplay(string id, ReaderSetReaderDisplayOptions options = null, RequestOptions requestOptions = null) { @@ -232,7 +261,8 @@ public virtual Reader SetReaderDisplay(string id, ReaderSetReaderDisplayOptions } /// - ///

Sets reader display to show cart details.

. + ///

Sets the reader display to show cart details.

. ///
public virtual Task SetReaderDisplayAsync(string id, ReaderSetReaderDisplayOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) { diff --git a/src/Stripe.net/Services/Terminal/Readers/ReaderSetReaderDisplayOptions.cs b/src/Stripe.net/Services/Terminal/Readers/ReaderSetReaderDisplayOptions.cs index c7bed33a55..abe18c57ab 100644 --- a/src/Stripe.net/Services/Terminal/Readers/ReaderSetReaderDisplayOptions.cs +++ b/src/Stripe.net/Services/Terminal/Readers/ReaderSetReaderDisplayOptions.cs @@ -9,7 +9,8 @@ namespace Stripe.Terminal public class ReaderSetReaderDisplayOptions : BaseOptions { /// - /// Cart. + /// Cart details to display on the reader screen, including line items, amounts, and + /// currency. /// [JsonProperty("cart")] #if NET6_0_OR_GREATER @@ -18,7 +19,7 @@ public class ReaderSetReaderDisplayOptions : BaseOptions public ReaderCartOptions Cart { get; set; } /// - /// Type. + /// Type of information to display. Only cart is currently supported. /// [JsonProperty("type")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/TestHelpers/Terminal/Readers/ReaderInteracPresentOptions.cs b/src/Stripe.net/Services/TestHelpers/Terminal/Readers/ReaderInteracPresentOptions.cs index c5ff2be0d5..b96c0064ef 100644 --- a/src/Stripe.net/Services/TestHelpers/Terminal/Readers/ReaderInteracPresentOptions.cs +++ b/src/Stripe.net/Services/TestHelpers/Terminal/Readers/ReaderInteracPresentOptions.cs @@ -9,7 +9,7 @@ namespace Stripe.TestHelpers.Terminal public class ReaderInteracPresentOptions : INestedOptions { /// - /// Card Number. + /// The Interac card number. /// [JsonProperty("number")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/Tokens/TokenAccountCompanyOptions.cs b/src/Stripe.net/Services/Tokens/TokenAccountCompanyOptions.cs index 4ff41ec6c6..cebe7ed292 100644 --- a/src/Stripe.net/Services/Tokens/TokenAccountCompanyOptions.cs +++ b/src/Stripe.net/Services/Tokens/TokenAccountCompanyOptions.cs @@ -194,6 +194,16 @@ public class TokenAccountCompanyOptions : INestedOptions #endif public string RegistrationNumber { get; set; } + /// + /// This hash is used to attest that the representative is authorized to act as the + /// representative of their legal entity. + /// + [JsonProperty("representative_declaration")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("representative_declaration")] +#endif + public TokenAccountCompanyRepresentativeDeclarationOptions RepresentativeDeclaration { get; set; } + /// /// The category identifying the legal structure of the company or legal entity. See Business diff --git a/src/Stripe.net/Services/Tokens/TokenAccountCompanyRepresentativeDeclarationOptions.cs b/src/Stripe.net/Services/Tokens/TokenAccountCompanyRepresentativeDeclarationOptions.cs new file mode 100644 index 0000000000..f43416c042 --- /dev/null +++ b/src/Stripe.net/Services/Tokens/TokenAccountCompanyRepresentativeDeclarationOptions.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 TokenAccountCompanyRepresentativeDeclarationOptions : INestedOptions + { + /// + /// The Unix timestamp marking when the representative 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 representative 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 representative 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/V2/Billing/CollectionSettings/CollectionSettingCreateEmailDeliveryOptions.cs b/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingCreateEmailDeliveryOptions.cs index c01725d8a1..dc09055eab 100644 --- a/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingCreateEmailDeliveryOptions.cs +++ b/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingCreateEmailDeliveryOptions.cs @@ -9,8 +9,8 @@ namespace Stripe.V2.Billing public class CollectionSettingCreateEmailDeliveryOptions : INestedOptions { /// - /// Controls emails for when the payment is due. For example after the invoice is finilized - /// and transition to Open state. + /// Controls emails for when the payment is due. For example after the invoice is finalized + /// and transitions to Open state. /// [JsonProperty("payment_due")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingCreateEmailDeliveryPaymentDueOptions.cs b/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingCreateEmailDeliveryPaymentDueOptions.cs index b87ea8b7ce..ac924ee09c 100644 --- a/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingCreateEmailDeliveryPaymentDueOptions.cs +++ b/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingCreateEmailDeliveryPaymentDueOptions.cs @@ -18,7 +18,7 @@ public class CollectionSettingCreateEmailDeliveryPaymentDueOptions : INestedOpti public bool? Enabled { get; set; } /// - /// If true the payment link to hosted invocie page would be included in email and PDF of + /// If true the payment link to hosted invoice page would be included in email and PDF of /// the invoice. /// [JsonProperty("include_payment_link")] diff --git a/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingUpdateEmailDeliveryOptions.cs b/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingUpdateEmailDeliveryOptions.cs index 125bfccfe9..3adf4c753f 100644 --- a/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingUpdateEmailDeliveryOptions.cs +++ b/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingUpdateEmailDeliveryOptions.cs @@ -9,8 +9,8 @@ namespace Stripe.V2.Billing public class CollectionSettingUpdateEmailDeliveryOptions : INestedOptions { /// - /// Controls emails for when the payment is due. For example after the invoice is finilized - /// and transition to Open state. + /// Controls emails for when the payment is due. For example after the invoice is finalized + /// and transitions to Open state. /// [JsonProperty("payment_due")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingUpdateEmailDeliveryPaymentDueOptions.cs b/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingUpdateEmailDeliveryPaymentDueOptions.cs index 67ef7114f6..1a4473046a 100644 --- a/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingUpdateEmailDeliveryPaymentDueOptions.cs +++ b/src/Stripe.net/Services/V2/Billing/CollectionSettings/CollectionSettingUpdateEmailDeliveryPaymentDueOptions.cs @@ -18,7 +18,7 @@ public class CollectionSettingUpdateEmailDeliveryPaymentDueOptions : INestedOpti public bool? Enabled { get; set; } /// - /// If true the payment link to hosted invocie page would be included in email and PDF of + /// If true the payment link to hosted invoice page would be included in email and PDF of /// the invoice. /// [JsonProperty("include_payment_link")] diff --git a/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateConfigurationCustomerAutomaticIndirectTaxOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateConfigurationCustomerAutomaticIndirectTaxOptions.cs index 8003fe2a9d..ced2458ef4 100644 --- a/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateConfigurationCustomerAutomaticIndirectTaxOptions.cs +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateConfigurationCustomerAutomaticIndirectTaxOptions.cs @@ -33,7 +33,8 @@ public class AccountCreateConfigurationCustomerAutomaticIndirectTaxOptions : INe /// The data source used to identify the customer's tax location - defaults to /// 'identity_address'. Will only be used for automatic tax calculation on the customer's /// Invoices and Subscriptions. - /// One of: identity_address, ip_address, or shipping_address. + /// One of: identity_address, ip_address, payment_method, or + /// shipping_address. /// [JsonProperty("location_source")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateConfigurationStorerCapabilitiesHoldsCurrenciesOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateConfigurationStorerCapabilitiesHoldsCurrenciesOptions.cs index c08f0bbeba..74c8a2eafd 100644 --- a/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateConfigurationStorerCapabilitiesHoldsCurrenciesOptions.cs +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateConfigurationStorerCapabilitiesHoldsCurrenciesOptions.cs @@ -16,5 +16,14 @@ public class AccountCreateConfigurationStorerCapabilitiesHoldsCurrenciesOptions [STJS.JsonPropertyName("gbp")] #endif public AccountCreateConfigurationStorerCapabilitiesHoldsCurrenciesGbpOptions Gbp { get; set; } + + /// + /// Can hold storage-type funds on Stripe in USD. + /// + [JsonProperty("usd")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("usd")] +#endif + public AccountCreateConfigurationStorerCapabilitiesHoldsCurrenciesUsdOptions Usd { get; set; } } } diff --git a/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateConfigurationStorerCapabilitiesHoldsCurrenciesUsdOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateConfigurationStorerCapabilitiesHoldsCurrenciesUsdOptions.cs new file mode 100644 index 0000000000..0f4128e09e --- /dev/null +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateConfigurationStorerCapabilitiesHoldsCurrenciesUsdOptions.cs @@ -0,0 +1,21 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountCreateConfigurationStorerCapabilitiesHoldsCurrenciesUsdOptions : INestedOptions + { + /// + /// To request a new Capability for an account, pass true. There can be a delay before the + /// requested Capability becomes active. + /// + [JsonProperty("requested")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("requested")] +#endif + public bool? Requested { get; set; } + } +} diff --git a/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateDefaultsResponsibilitiesOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateDefaultsResponsibilitiesOptions.cs index ac55a66c89..aa142110ac 100644 --- a/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateDefaultsResponsibilitiesOptions.cs +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateDefaultsResponsibilitiesOptions.cs @@ -10,7 +10,8 @@ public class AccountCreateDefaultsResponsibilitiesOptions : INestedOptions { /// /// A value indicating the party responsible for collecting fees from this account. - /// One of: application, or stripe. + /// One of: application, application_custom, application_express, or + /// stripe. /// [JsonProperty("fees_collector")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateIdentityAttestationsOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateIdentityAttestationsOptions.cs index 336316a764..e84a868e3a 100644 --- a/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateIdentityAttestationsOptions.cs +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateIdentityAttestationsOptions.cs @@ -37,6 +37,16 @@ public class AccountCreateIdentityAttestationsOptions : INestedOptions #endif public AccountCreateIdentityAttestationsPersonsProvidedOptions PersonsProvided { get; set; } + /// + /// This hash is used to attest that the representative is authorized to act as the + /// representative of their legal entity. + /// + [JsonProperty("representative_declaration")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("representative_declaration")] +#endif + public AccountCreateIdentityAttestationsRepresentativeDeclarationOptions RepresentativeDeclaration { get; set; } + /// /// Attestations of accepted terms of service agreements. /// diff --git a/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateIdentityAttestationsRepresentativeDeclarationOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateIdentityAttestationsRepresentativeDeclarationOptions.cs new file mode 100644 index 0000000000..94891268db --- /dev/null +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateIdentityAttestationsRepresentativeDeclarationOptions.cs @@ -0,0 +1,41 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core +{ + using System; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountCreateIdentityAttestationsRepresentativeDeclarationOptions : INestedOptions + { + /// + /// The time marking when the representative attestation was made. Represented as a RFC 3339 + /// date & time UTC value in millisecond precision, for example: + /// 2022-09-18T13:22:18.123Z. + /// + [JsonProperty("date")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("date")] +#endif + public DateTime? Date { get; set; } + + /// + /// The IP address from which the representative 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 representative 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/V2/Core/Accounts/AccountCreateIdentityOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateIdentityOptions.cs index 8d1377621b..1060c19280 100644 --- a/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateIdentityOptions.cs +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountCreateIdentityOptions.cs @@ -9,7 +9,8 @@ namespace Stripe.V2.Core public class AccountCreateIdentityOptions : INestedOptions { /// - /// Attestations from the identity's key people, e.g. owners, executives, directors. + /// Attestations from the identity's key people, e.g. owners, executives, directors, + /// representatives. /// [JsonProperty("attestations")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/V2/Core/Accounts/AccountListOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountListOptions.cs index a3ce131f43..6ca93567d6 100644 --- a/src/Stripe.net/Services/V2/Core/Accounts/AccountListOptions.cs +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountListOptions.cs @@ -18,5 +18,15 @@ public class AccountListOptions : V2.ListOptions [STJS.JsonPropertyName("applied_configurations")] #endif public List AppliedConfigurations { get; set; } + + /// + /// Filter by whether the account is closed. If omitted, returns only Accounts that are not + /// closed. + /// + [JsonProperty("closed")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("closed")] +#endif + public bool? Closed { get; set; } } } diff --git a/src/Stripe.net/Services/V2/Core/Accounts/AccountService.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountService.cs index 5d2a4895b5..a3e06f358b 100644 --- a/src/Stripe.net/Services/V2/Core/Accounts/AccountService.cs +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountService.cs @@ -26,7 +26,9 @@ internal AccountService(IStripeClient client) this.Requestor); /// - /// Removes access to the Account and its associated resources. + /// Removes access to the Account and its associated resources. Closed Accounts can no + /// longer be operated on, but limited information can still be retrieved through the API in + /// order to be able to track their history. /// public virtual Account Close(string id, AccountCloseOptions options = null, RequestOptions requestOptions = null) { @@ -34,7 +36,9 @@ public virtual Account Close(string id, AccountCloseOptions options = null, Requ } /// - /// Removes access to the Account and its associated resources. + /// Removes access to the Account and its associated resources. Closed Accounts can no + /// longer be operated on, but limited information can still be retrieved through the API in + /// order to be able to track their history. /// public virtual Task CloseAsync(string id, AccountCloseOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) { diff --git a/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateConfigurationCustomerAutomaticIndirectTaxOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateConfigurationCustomerAutomaticIndirectTaxOptions.cs index 7037521b51..d69c3a0f97 100644 --- a/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateConfigurationCustomerAutomaticIndirectTaxOptions.cs +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateConfigurationCustomerAutomaticIndirectTaxOptions.cs @@ -33,7 +33,8 @@ public class AccountUpdateConfigurationCustomerAutomaticIndirectTaxOptions : INe /// The data source used to identify the customer's tax location - defaults to /// 'identity_address'. Will only be used for automatic tax calculation on the customer's /// Invoices and Subscriptions. - /// One of: identity_address, ip_address, or shipping_address. + /// One of: identity_address, ip_address, payment_method, or + /// shipping_address. ///
[JsonProperty("location_source")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateConfigurationStorerCapabilitiesHoldsCurrenciesOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateConfigurationStorerCapabilitiesHoldsCurrenciesOptions.cs index 10f8f0ab87..e8570b91d5 100644 --- a/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateConfigurationStorerCapabilitiesHoldsCurrenciesOptions.cs +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateConfigurationStorerCapabilitiesHoldsCurrenciesOptions.cs @@ -16,5 +16,14 @@ public class AccountUpdateConfigurationStorerCapabilitiesHoldsCurrenciesOptions [STJS.JsonPropertyName("gbp")] #endif public AccountUpdateConfigurationStorerCapabilitiesHoldsCurrenciesGbpOptions Gbp { get; set; } + + /// + /// Can hold storage-type funds on Stripe in USD. + /// + [JsonProperty("usd")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("usd")] +#endif + public AccountUpdateConfigurationStorerCapabilitiesHoldsCurrenciesUsdOptions Usd { get; set; } } } diff --git a/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateConfigurationStorerCapabilitiesHoldsCurrenciesUsdOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateConfigurationStorerCapabilitiesHoldsCurrenciesUsdOptions.cs new file mode 100644 index 0000000000..53a9ccb98f --- /dev/null +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateConfigurationStorerCapabilitiesHoldsCurrenciesUsdOptions.cs @@ -0,0 +1,21 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountUpdateConfigurationStorerCapabilitiesHoldsCurrenciesUsdOptions : INestedOptions + { + /// + /// To request a new Capability for an account, pass true. There can be a delay before the + /// requested Capability becomes active. + /// + [JsonProperty("requested")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("requested")] +#endif + public bool? Requested { get; set; } + } +} diff --git a/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateDefaultsResponsibilitiesOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateDefaultsResponsibilitiesOptions.cs index fbd121b71d..73b3b422c1 100644 --- a/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateDefaultsResponsibilitiesOptions.cs +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateDefaultsResponsibilitiesOptions.cs @@ -10,7 +10,8 @@ public class AccountUpdateDefaultsResponsibilitiesOptions : INestedOptions { /// /// A value indicating the party responsible for collecting fees from this account. - /// One of: application, or stripe. + /// One of: application, application_custom, application_express, or + /// stripe. /// [JsonProperty("fees_collector")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateIdentityAttestationsOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateIdentityAttestationsOptions.cs index 0bcf540b0c..76c829ea34 100644 --- a/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateIdentityAttestationsOptions.cs +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateIdentityAttestationsOptions.cs @@ -37,6 +37,16 @@ public class AccountUpdateIdentityAttestationsOptions : INestedOptions #endif public AccountUpdateIdentityAttestationsPersonsProvidedOptions PersonsProvided { get; set; } + /// + /// This hash is used to attest that the representative is authorized to act as the + /// representative of their legal entity. + /// + [JsonProperty("representative_declaration")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("representative_declaration")] +#endif + public AccountUpdateIdentityAttestationsRepresentativeDeclarationOptions RepresentativeDeclaration { get; set; } + /// /// Attestations of accepted terms of service agreements. /// diff --git a/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateIdentityAttestationsRepresentativeDeclarationOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateIdentityAttestationsRepresentativeDeclarationOptions.cs new file mode 100644 index 0000000000..d298fd331c --- /dev/null +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateIdentityAttestationsRepresentativeDeclarationOptions.cs @@ -0,0 +1,41 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core +{ + using System; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class AccountUpdateIdentityAttestationsRepresentativeDeclarationOptions : INestedOptions + { + /// + /// The time marking when the representative attestation was made. Represented as a RFC 3339 + /// date & time UTC value in millisecond precision, for example: + /// 2022-09-18T13:22:18.123Z. + /// + [JsonProperty("date")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("date")] +#endif + public DateTime? Date { get; set; } + + /// + /// The IP address from which the representative 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 representative 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/V2/Core/Accounts/AccountUpdateIdentityOptions.cs b/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateIdentityOptions.cs index 7fb192f5c9..8f9e419e1e 100644 --- a/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateIdentityOptions.cs +++ b/src/Stripe.net/Services/V2/Core/Accounts/AccountUpdateIdentityOptions.cs @@ -9,7 +9,8 @@ namespace Stripe.V2.Core public class AccountUpdateIdentityOptions : INestedOptions { /// - /// Attestations from the identity's key people, e.g. owners, executives, directors. + /// Attestations from the identity's key people, e.g. owners, executives, directors, + /// representatives. /// [JsonProperty("attestations")] #if NET6_0_OR_GREATER diff --git a/src/Stripe.net/Services/V2/Core/Events/EventListOptions.cs b/src/Stripe.net/Services/V2/Core/Events/EventListOptions.cs index 49db479c1a..db38556e8c 100644 --- a/src/Stripe.net/Services/V2/Core/Events/EventListOptions.cs +++ b/src/Stripe.net/Services/V2/Core/Events/EventListOptions.cs @@ -1,6 +1,8 @@ // File generated from our OpenAPI spec namespace Stripe.V2.Core { + using System; + using System.Collections.Generic; using Newtonsoft.Json; #if NET6_0_OR_GREATER using STJS = System.Text.Json.Serialization; @@ -8,6 +10,42 @@ namespace Stripe.V2.Core public class EventListOptions : V2.ListOptions { + /// + /// Filter for events created after the specified timestamp. + /// + [JsonProperty("gt")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("gt")] +#endif + public DateTime? Gt { get; set; } + + /// + /// Filter for events created at or after the specified timestamp. + /// + [JsonProperty("gte")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("gte")] +#endif + public DateTime? Gte { get; set; } + + /// + /// Filter for events created before the specified timestamp. + /// + [JsonProperty("lt")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("lt")] +#endif + public DateTime? Lt { get; set; } + + /// + /// Filter for events created at or before the specified timestamp. + /// + [JsonProperty("lte")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("lte")] +#endif + public DateTime? Lte { get; set; } + /// /// Primary object ID used to retrieve related events. /// @@ -16,5 +54,14 @@ public class EventListOptions : V2.ListOptions [STJS.JsonPropertyName("object_id")] #endif public string ObjectId { get; set; } + + /// + /// An array of up to 20 strings containing specific event names. + /// + [JsonProperty("types")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("types")] +#endif + public List Types { get; set; } } } diff --git a/src/Stripe.net/Services/V2/Core/Vault/GbBankAccounts/GbBankAccountListOptions.cs b/src/Stripe.net/Services/V2/Core/Vault/GbBankAccounts/GbBankAccountListOptions.cs new file mode 100644 index 0000000000..82052423fa --- /dev/null +++ b/src/Stripe.net/Services/V2/Core/Vault/GbBankAccounts/GbBankAccountListOptions.cs @@ -0,0 +1,7 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core.Vault +{ + public class GbBankAccountListOptions : V2.ListOptions + { + } +} diff --git a/src/Stripe.net/Services/V2/Core/Vault/GbBankAccounts/GbBankAccountService.cs b/src/Stripe.net/Services/V2/Core/Vault/GbBankAccounts/GbBankAccountService.cs index 82fbd89d75..0fcd4b5137 100644 --- a/src/Stripe.net/Services/V2/Core/Vault/GbBankAccounts/GbBankAccountService.cs +++ b/src/Stripe.net/Services/V2/Core/Vault/GbBankAccounts/GbBankAccountService.cs @@ -2,6 +2,7 @@ namespace Stripe.V2.Core.Vault { using System; + using System.Collections.Generic; using System.Net; using System.Net.Http; using System.Threading; @@ -114,5 +115,41 @@ public virtual Task InitiateConfirmationOfPayeeAsync(string id, G { return this.RequestAsync(BaseAddress.Api, HttpMethod.Post, $"/v2/core/vault/gb_bank_accounts/{WebUtility.UrlEncode(id)}/initiate_confirmation_of_payee", options, requestOptions, cancellationToken); } + + /// + /// List objects that can be used as destinations for outbound money movement via + /// OutboundPayment. + /// + public virtual V2.StripeList List(GbBankAccountListOptions options = null, RequestOptions requestOptions = null) + { + return this.Request>(BaseAddress.Api, HttpMethod.Get, $"/v2/core/vault/gb_bank_accounts", options, requestOptions); + } + + /// + /// List objects that can be used as destinations for outbound money movement via + /// OutboundPayment. + /// + public virtual Task> ListAsync(GbBankAccountListOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) + { + return this.RequestAsync>(BaseAddress.Api, HttpMethod.Get, $"/v2/core/vault/gb_bank_accounts", options, requestOptions, cancellationToken); + } + + /// + /// List objects that can be used as destinations for outbound money movement via + /// OutboundPayment. + /// + public virtual IEnumerable ListAutoPaging(GbBankAccountListOptions options = null, RequestOptions requestOptions = null) + { + return this.ListRequestAutoPaging($"/v2/core/vault/gb_bank_accounts", options, requestOptions); + } + + /// + /// List objects that can be used as destinations for outbound money movement via + /// OutboundPayment. + /// + public virtual IAsyncEnumerable ListAutoPagingAsync(GbBankAccountListOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) + { + return this.ListRequestAutoPagingAsync($"/v2/core/vault/gb_bank_accounts", options, requestOptions, cancellationToken); + } } } diff --git a/src/Stripe.net/Services/V2/Core/Vault/UsBankAccounts/UsBankAccountConfirmMicrodepositsOptions.cs b/src/Stripe.net/Services/V2/Core/Vault/UsBankAccounts/UsBankAccountConfirmMicrodepositsOptions.cs new file mode 100644 index 0000000000..85ad04784d --- /dev/null +++ b/src/Stripe.net/Services/V2/Core/Vault/UsBankAccounts/UsBankAccountConfirmMicrodepositsOptions.cs @@ -0,0 +1,32 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core.Vault +{ + using System.Collections.Generic; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class UsBankAccountConfirmMicrodepositsOptions : BaseOptions + { + /// + /// Two amounts received through Send Microdeposits must match the input to Confirm + /// Microdeposits to verify US Bank Account. + /// + [JsonProperty("amounts")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("amounts")] +#endif + public List Amounts { get; set; } + + /// + /// Descriptor code received through Send Microdeposits must match the input to Confirm + /// Microdeposits to verify US Bank Account. + /// + [JsonProperty("descriptor_code")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("descriptor_code")] +#endif + public string DescriptorCode { get; set; } + } +} diff --git a/src/Stripe.net/Services/V2/Core/Vault/UsBankAccounts/UsBankAccountListOptions.cs b/src/Stripe.net/Services/V2/Core/Vault/UsBankAccounts/UsBankAccountListOptions.cs new file mode 100644 index 0000000000..83e5c0e64e --- /dev/null +++ b/src/Stripe.net/Services/V2/Core/Vault/UsBankAccounts/UsBankAccountListOptions.cs @@ -0,0 +1,21 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core.Vault +{ + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class UsBankAccountListOptions : V2.ListOptions + { + /// + /// Optionally filter by verification status. Mutually exclusive with unverified, + /// verified, awaiting_verification, and verification_failed. + /// + [JsonProperty("verification_status")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("verification_status")] +#endif + public string VerificationStatus { get; set; } + } +} diff --git a/src/Stripe.net/Services/V2/Core/Vault/UsBankAccounts/UsBankAccountSendMicrodepositsOptions.cs b/src/Stripe.net/Services/V2/Core/Vault/UsBankAccounts/UsBankAccountSendMicrodepositsOptions.cs new file mode 100644 index 0000000000..09cdc15c35 --- /dev/null +++ b/src/Stripe.net/Services/V2/Core/Vault/UsBankAccounts/UsBankAccountSendMicrodepositsOptions.cs @@ -0,0 +1,7 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.Core.Vault +{ + public class UsBankAccountSendMicrodepositsOptions : BaseOptions + { + } +} diff --git a/src/Stripe.net/Services/V2/Core/Vault/UsBankAccounts/UsBankAccountService.cs b/src/Stripe.net/Services/V2/Core/Vault/UsBankAccounts/UsBankAccountService.cs index ac5d7b2a9a..5ac7966120 100644 --- a/src/Stripe.net/Services/V2/Core/Vault/UsBankAccounts/UsBankAccountService.cs +++ b/src/Stripe.net/Services/V2/Core/Vault/UsBankAccounts/UsBankAccountService.cs @@ -2,6 +2,7 @@ namespace Stripe.V2.Core.Vault { using System; + using System.Collections.Generic; using System.Net; using System.Net.Http; using System.Threading; @@ -39,6 +40,26 @@ public virtual Task ArchiveAsync(string id, UsBankAccountArchiveO return this.RequestAsync(BaseAddress.Api, HttpMethod.Post, $"/v2/core/vault/us_bank_accounts/{WebUtility.UrlEncode(id)}/archive", options, requestOptions, cancellationToken); } + /// + /// Confirm microdeposits amounts or descriptor code that you have received from the Send + /// Microdeposits request. Once you correctly confirm this, this US Bank Account will be + /// verified and eligible to transfer funds with. + /// + public virtual UsBankAccount ConfirmMicrodeposits(string id, UsBankAccountConfirmMicrodepositsOptions options = null, RequestOptions requestOptions = null) + { + return this.Request(BaseAddress.Api, HttpMethod.Post, $"/v2/core/vault/us_bank_accounts/{WebUtility.UrlEncode(id)}/confirm_microdeposits", options, requestOptions); + } + + /// + /// Confirm microdeposits amounts or descriptor code that you have received from the Send + /// Microdeposits request. Once you correctly confirm this, this US Bank Account will be + /// verified and eligible to transfer funds with. + /// + public virtual Task ConfirmMicrodepositsAsync(string id, UsBankAccountConfirmMicrodepositsOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) + { + return this.RequestAsync(BaseAddress.Api, HttpMethod.Post, $"/v2/core/vault/us_bank_accounts/{WebUtility.UrlEncode(id)}/confirm_microdeposits", options, requestOptions, cancellationToken); + } + /// /// Create a USBankAccount object. /// @@ -71,6 +92,58 @@ public virtual Task GetAsync(string id, UsBankAccountGetOptions o return this.RequestAsync(BaseAddress.Api, HttpMethod.Get, $"/v2/core/vault/us_bank_accounts/{WebUtility.UrlEncode(id)}", options, requestOptions, cancellationToken); } + /// + /// List USBankAccount objects. Optionally filter by verification status. + /// + public virtual V2.StripeList List(UsBankAccountListOptions options = null, RequestOptions requestOptions = null) + { + return this.Request>(BaseAddress.Api, HttpMethod.Get, $"/v2/core/vault/us_bank_accounts", options, requestOptions); + } + + /// + /// List USBankAccount objects. Optionally filter by verification status. + /// + public virtual Task> ListAsync(UsBankAccountListOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) + { + return this.RequestAsync>(BaseAddress.Api, HttpMethod.Get, $"/v2/core/vault/us_bank_accounts", options, requestOptions, cancellationToken); + } + + /// + /// List USBankAccount objects. Optionally filter by verification status. + /// + public virtual IEnumerable ListAutoPaging(UsBankAccountListOptions options = null, RequestOptions requestOptions = null) + { + return this.ListRequestAutoPaging($"/v2/core/vault/us_bank_accounts", options, requestOptions); + } + + /// + /// List USBankAccount objects. Optionally filter by verification status. + /// + public virtual IAsyncEnumerable ListAutoPagingAsync(UsBankAccountListOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) + { + return this.ListRequestAutoPagingAsync($"/v2/core/vault/us_bank_accounts", options, requestOptions, cancellationToken); + } + + /// + /// Send microdeposits in order to verify your US Bank Account so it is eligible to transfer + /// funds. This will start the verification process and you must Confirm Microdeposits to + /// successfully verify your US Bank Account. + /// + public virtual UsBankAccount SendMicrodeposits(string id, UsBankAccountSendMicrodepositsOptions options = null, RequestOptions requestOptions = null) + { + return this.Request(BaseAddress.Api, HttpMethod.Post, $"/v2/core/vault/us_bank_accounts/{WebUtility.UrlEncode(id)}/send_microdeposits", options, requestOptions); + } + + /// + /// Send microdeposits in order to verify your US Bank Account so it is eligible to transfer + /// funds. This will start the verification process and you must Confirm Microdeposits to + /// successfully verify your US Bank Account. + /// + public virtual Task SendMicrodepositsAsync(string id, UsBankAccountSendMicrodepositsOptions options = null, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) + { + return this.RequestAsync(BaseAddress.Api, HttpMethod.Post, $"/v2/core/vault/us_bank_accounts/{WebUtility.UrlEncode(id)}/send_microdeposits", options, requestOptions, cancellationToken); + } + /// /// Update a USBankAccount object. This is limited to supplying a previously empty /// routing_number field. diff --git a/src/Stripe.net/Services/V2/MoneyManagement/FinancialAccounts/FinancialAccountService.cs b/src/Stripe.net/Services/V2/MoneyManagement/FinancialAccounts/FinancialAccountService.cs index 231eaacb63..4bf9506fcb 100644 --- a/src/Stripe.net/Services/V2/MoneyManagement/FinancialAccounts/FinancialAccountService.cs +++ b/src/Stripe.net/Services/V2/MoneyManagement/FinancialAccounts/FinancialAccountService.cs @@ -99,5 +99,21 @@ public virtual IAsyncEnumerable ListAutoPagingAsync(FinancialA { return this.ListRequestAutoPagingAsync($"/v2/money_management/financial_accounts", options, requestOptions, cancellationToken); } + + /// + /// Updates an existing FinancialAccount. + /// + public virtual FinancialAccount Update(string id, FinancialAccountUpdateOptions options, RequestOptions requestOptions = null) + { + return this.Request(BaseAddress.Api, HttpMethod.Post, $"/v2/money_management/financial_accounts/{WebUtility.UrlEncode(id)}", options, requestOptions); + } + + /// + /// Updates an existing FinancialAccount. + /// + public virtual Task UpdateAsync(string id, FinancialAccountUpdateOptions options, RequestOptions requestOptions = null, CancellationToken cancellationToken = default) + { + return this.RequestAsync(BaseAddress.Api, HttpMethod.Post, $"/v2/money_management/financial_accounts/{WebUtility.UrlEncode(id)}", options, requestOptions, cancellationToken); + } } } diff --git a/src/Stripe.net/Services/V2/MoneyManagement/FinancialAccounts/FinancialAccountUpdateOptions.cs b/src/Stripe.net/Services/V2/MoneyManagement/FinancialAccounts/FinancialAccountUpdateOptions.cs new file mode 100644 index 0000000000..72f1e9796c --- /dev/null +++ b/src/Stripe.net/Services/V2/MoneyManagement/FinancialAccounts/FinancialAccountUpdateOptions.cs @@ -0,0 +1,31 @@ +// File generated from our OpenAPI spec +namespace Stripe.V2.MoneyManagement +{ + using System.Collections.Generic; + using Newtonsoft.Json; +#if NET6_0_OR_GREATER + using STJS = System.Text.Json.Serialization; +#endif + + public class FinancialAccountUpdateOptions : BaseOptions, IHasMetadata + { + /// + /// A descriptive name for the FinancialAccount, up to 50 characters long. This name will be + /// used in the Stripe Dashboard and embedded components. + /// + [JsonProperty("display_name")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("display_name")] +#endif + public string DisplayName { get; set; } + + /// + /// Metadata associated with the FinancialAccount. + /// + [JsonProperty("metadata")] +#if NET6_0_OR_GREATER + [STJS.JsonPropertyName("metadata")] +#endif + public Dictionary Metadata { get; set; } + } +} diff --git a/src/Stripe.net/Services/WebhookEndpoints/WebhookEndpointCreateOptions.cs b/src/Stripe.net/Services/WebhookEndpoints/WebhookEndpointCreateOptions.cs index 58c55ec184..c49bbec1e1 100644 --- a/src/Stripe.net/Services/WebhookEndpoints/WebhookEndpointCreateOptions.cs +++ b/src/Stripe.net/Services/WebhookEndpoints/WebhookEndpointCreateOptions.cs @@ -41,8 +41,8 @@ public class WebhookEndpointCreateOptions : BaseOptions, IHasMetadata /// 2024-10-28.acacia, 2024-11-20.acacia, 2024-12-18.acacia, /// 2025-01-27.acacia, 2025-02-24.acacia, 2025-03-01.dashboard, /// 2025-03-31.basil, 2025-04-30.basil, 2025-05-28.basil, - /// 2025-06-30.basil, 2025-07-30.basil, 2025-08-27.basil, or - /// 2025-09-30.clover. + /// 2025-06-30.basil, 2025-07-30.basil, 2025-08-27.basil, + /// 2025-09-30.clover, or 2025-10-29.clover. /// [JsonProperty("api_version")] #if NET6_0_OR_GREATER diff --git a/src/StripeTests/Services/GeneratedExamplesTest.cs b/src/StripeTests/Services/GeneratedExamplesTest.cs index 1be7b6c0d7..9fa4dd5563 100644 --- a/src/StripeTests/Services/GeneratedExamplesTest.cs +++ b/src/StripeTests/Services/GeneratedExamplesTest.cs @@ -3093,6 +3093,22 @@ public void TestPromotionCodesGet2() [Fact] public void TestPromotionCodesPost() + { + var options = new PromotionCodeCreateOptions + { + Promotion = new PromotionCodePromotionOptions + { + Type = "coupon", + Coupon = "Z4OV52SU", + }, + }; + var service = new PromotionCodeService(this.StripeClient); + PromotionCode promotionCode = service.Create(options); + this.AssertRequest(HttpMethod.Post, "/v1/promotion_codes"); + } + + [Fact] + public void TestPromotionCodesPost2() { var options = new PromotionCodeUpdateOptions { @@ -6882,20 +6898,11 @@ public void TestV2CoreEventGet() HttpMethod.Get, "/v2/core/events", (HttpStatusCode)200, - "{\"data\":[{\"id\":\"obj_123\",\"object\":\"v2.core.event\",\"created\":\"1970-01-12T21:42:34.472Z\",\"livemode\":true,\"type\":\"type\"}],\"next_page_url\":null,\"previous_page_url\":null}", - "object_id=object_id"); - var options = new Stripe.V2.Core.EventListOptions - { - ObjectId = "object_id", - }; + "{\"data\":[{\"id\":\"obj_123\",\"object\":\"v2.core.event\",\"created\":\"1970-01-12T21:42:34.472Z\",\"livemode\":true,\"type\":\"type\"}],\"next_page_url\":null,\"previous_page_url\":null}"); var client = new StripeClient(this.Requestor); var service = client.V2.Core.Events; - Stripe.V2.StripeList events = service.List( - options); - this.AssertRequest( - HttpMethod.Get, - "/v2/core/events", - "object_id=object_id"); + Stripe.V2.StripeList events = service.List(); + this.AssertRequest(HttpMethod.Get, "/v2/core/events"); } [Fact] @@ -7051,6 +7058,23 @@ public void TestV2CoreEventDestinationPost5() "/v2/core/event_destinations/id_123/ping"); } + [Fact] + public void TestV2CoreVaultGbBankAccountGet() + { + this.StubRequest( + HttpMethod.Get, + "/v2/core/vault/gb_bank_accounts", + (HttpStatusCode)200, + "{\"data\":[{\"id\":\"obj_123\",\"object\":\"v2.core.vault.gb_bank_account\",\"archived\":true,\"bank_account_type\":\"savings\",\"bank_name\":\"bank_name\",\"confirmation_of_payee\":{\"result\":{\"created\":\"1970-01-12T21:42:34.472Z\",\"match_result\":\"unavailable\",\"matched\":{},\"message\":\"message\",\"provided\":{\"business_type\":\"personal\",\"name\":\"name\"}},\"status\":\"awaiting_acknowledgement\"},\"created\":\"1970-01-12T21:42:34.472Z\",\"last4\":\"last4\",\"livemode\":true,\"sort_code\":\"sort_code\"}],\"next_page_url\":null,\"previous_page_url\":null}"); + var client = new StripeClient(this.Requestor); + var service = client.V2.Core.Vault.GbBankAccounts; + Stripe.V2.StripeList gbBankAccounts = service + .List(); + this.AssertRequest( + HttpMethod.Get, + "/v2/core/vault/gb_bank_accounts"); + } + [Fact] public void TestV2CoreVaultGbBankAccountPost() { @@ -7074,7 +7098,7 @@ public void TestV2CoreVaultGbBankAccountPost() } [Fact] - public void TestV2CoreVaultGbBankAccountGet() + public void TestV2CoreVaultGbBankAccountGet2() { this.StubRequest( HttpMethod.Get, @@ -7141,6 +7165,23 @@ public void TestV2CoreVaultGbBankAccountPost4() "/v2/core/vault/gb_bank_accounts/id_123/initiate_confirmation_of_payee"); } + [Fact] + public void TestV2CoreVaultUsBankAccountGet() + { + this.StubRequest( + HttpMethod.Get, + "/v2/core/vault/us_bank_accounts", + (HttpStatusCode)200, + "{\"data\":[{\"id\":\"obj_123\",\"object\":\"v2.core.vault.us_bank_account\",\"archived\":true,\"bank_account_type\":\"savings\",\"bank_name\":\"bank_name\",\"created\":\"1970-01-12T21:42:34.472Z\",\"last4\":\"last4\",\"livemode\":true,\"verification\":{\"status\":\"verification_failed\"}}],\"next_page_url\":null,\"previous_page_url\":null}"); + var client = new StripeClient(this.Requestor); + var service = client.V2.Core.Vault.UsBankAccounts; + Stripe.V2.StripeList usBankAccounts = service + .List(); + this.AssertRequest( + HttpMethod.Get, + "/v2/core/vault/us_bank_accounts"); + } + [Fact] public void TestV2CoreVaultUsBankAccountPost() { @@ -7148,7 +7189,7 @@ public void TestV2CoreVaultUsBankAccountPost() HttpMethod.Post, "/v2/core/vault/us_bank_accounts", (HttpStatusCode)200, - "{\"id\":\"obj_123\",\"object\":\"v2.core.vault.us_bank_account\",\"archived\":true,\"bank_account_type\":\"savings\",\"bank_name\":\"bank_name\",\"created\":\"1970-01-12T21:42:34.472Z\",\"last4\":\"last4\",\"livemode\":true}"); + "{\"id\":\"obj_123\",\"object\":\"v2.core.vault.us_bank_account\",\"archived\":true,\"bank_account_type\":\"savings\",\"bank_name\":\"bank_name\",\"created\":\"1970-01-12T21:42:34.472Z\",\"last4\":\"last4\",\"livemode\":true,\"verification\":{\"status\":\"verification_failed\"}}"); var options = new Stripe.V2.Core.Vault.UsBankAccountCreateOptions { AccountNumber = "account_number", @@ -7163,13 +7204,13 @@ public void TestV2CoreVaultUsBankAccountPost() } [Fact] - public void TestV2CoreVaultUsBankAccountGet() + public void TestV2CoreVaultUsBankAccountGet2() { this.StubRequest( HttpMethod.Get, "/v2/core/vault/us_bank_accounts/id_123", (HttpStatusCode)200, - "{\"id\":\"obj_123\",\"object\":\"v2.core.vault.us_bank_account\",\"archived\":true,\"bank_account_type\":\"savings\",\"bank_name\":\"bank_name\",\"created\":\"1970-01-12T21:42:34.472Z\",\"last4\":\"last4\",\"livemode\":true}"); + "{\"id\":\"obj_123\",\"object\":\"v2.core.vault.us_bank_account\",\"archived\":true,\"bank_account_type\":\"savings\",\"bank_name\":\"bank_name\",\"created\":\"1970-01-12T21:42:34.472Z\",\"last4\":\"last4\",\"livemode\":true,\"verification\":{\"status\":\"verification_failed\"}}"); var client = new StripeClient(this.Requestor); var service = client.V2.Core.Vault.UsBankAccounts; Stripe.V2.Core.Vault.UsBankAccount usBankAccount = service.Get( @@ -7186,7 +7227,7 @@ public void TestV2CoreVaultUsBankAccountPost2() HttpMethod.Post, "/v2/core/vault/us_bank_accounts/id_123", (HttpStatusCode)200, - "{\"id\":\"obj_123\",\"object\":\"v2.core.vault.us_bank_account\",\"archived\":true,\"bank_account_type\":\"savings\",\"bank_name\":\"bank_name\",\"created\":\"1970-01-12T21:42:34.472Z\",\"last4\":\"last4\",\"livemode\":true}"); + "{\"id\":\"obj_123\",\"object\":\"v2.core.vault.us_bank_account\",\"archived\":true,\"bank_account_type\":\"savings\",\"bank_name\":\"bank_name\",\"created\":\"1970-01-12T21:42:34.472Z\",\"last4\":\"last4\",\"livemode\":true,\"verification\":{\"status\":\"verification_failed\"}}"); var options = new Stripe.V2.Core.Vault.UsBankAccountUpdateOptions(); var client = new StripeClient(this.Requestor); var service = client.V2.Core.Vault.UsBankAccounts; @@ -7205,7 +7246,7 @@ public void TestV2CoreVaultUsBankAccountPost3() HttpMethod.Post, "/v2/core/vault/us_bank_accounts/id_123/archive", (HttpStatusCode)200, - "{\"id\":\"obj_123\",\"object\":\"v2.core.vault.us_bank_account\",\"archived\":true,\"bank_account_type\":\"savings\",\"bank_name\":\"bank_name\",\"created\":\"1970-01-12T21:42:34.472Z\",\"last4\":\"last4\",\"livemode\":true}"); + "{\"id\":\"obj_123\",\"object\":\"v2.core.vault.us_bank_account\",\"archived\":true,\"bank_account_type\":\"savings\",\"bank_name\":\"bank_name\",\"created\":\"1970-01-12T21:42:34.472Z\",\"last4\":\"last4\",\"livemode\":true,\"verification\":{\"status\":\"verification_failed\"}}"); var client = new StripeClient(this.Requestor); var service = client.V2.Core.Vault.UsBankAccounts; Stripe.V2.Core.Vault.UsBankAccount usBankAccount = service.Archive( @@ -7215,6 +7256,40 @@ public void TestV2CoreVaultUsBankAccountPost3() "/v2/core/vault/us_bank_accounts/id_123/archive"); } + [Fact] + public void TestV2CoreVaultUsBankAccountPost4() + { + this.StubRequest( + HttpMethod.Post, + "/v2/core/vault/us_bank_accounts/id_123/confirm_microdeposits", + (HttpStatusCode)200, + "{\"id\":\"obj_123\",\"object\":\"v2.core.vault.us_bank_account\",\"archived\":true,\"bank_account_type\":\"savings\",\"bank_name\":\"bank_name\",\"created\":\"1970-01-12T21:42:34.472Z\",\"last4\":\"last4\",\"livemode\":true,\"verification\":{\"status\":\"verification_failed\"}}"); + var client = new StripeClient(this.Requestor); + var service = client.V2.Core.Vault.UsBankAccounts; + Stripe.V2.Core.Vault.UsBankAccount usBankAccount = service + .ConfirmMicrodeposits("id_123"); + this.AssertRequest( + HttpMethod.Post, + "/v2/core/vault/us_bank_accounts/id_123/confirm_microdeposits"); + } + + [Fact] + public void TestV2CoreVaultUsBankAccountPost5() + { + this.StubRequest( + HttpMethod.Post, + "/v2/core/vault/us_bank_accounts/id_123/send_microdeposits", + (HttpStatusCode)200, + "{\"id\":\"obj_123\",\"object\":\"v2.core.vault.us_bank_account\",\"archived\":true,\"bank_account_type\":\"savings\",\"bank_name\":\"bank_name\",\"created\":\"1970-01-12T21:42:34.472Z\",\"last4\":\"last4\",\"livemode\":true,\"verification\":{\"status\":\"verification_failed\"}}"); + var client = new StripeClient(this.Requestor); + var service = client.V2.Core.Vault.UsBankAccounts; + Stripe.V2.Core.Vault.UsBankAccount usBankAccount = service + .SendMicrodeposits("id_123"); + this.AssertRequest( + HttpMethod.Post, + "/v2/core/vault/us_bank_accounts/id_123/send_microdeposits"); + } + [Fact] public void TestV2MoneyManagementAdjustmentGet() { @@ -7306,6 +7381,24 @@ public void TestV2MoneyManagementFinancialAccountGet2() [Fact] public void TestV2MoneyManagementFinancialAccountPost2() + { + this.StubRequest( + HttpMethod.Post, + "/v2/money_management/financial_accounts/id_123", + (HttpStatusCode)200, + "{\"id\":\"obj_123\",\"object\":\"v2.money_management.financial_account\",\"balance\":{\"available\":{\"key\":{\"currency\":\"USD\",\"value\":35}},\"inbound_pending\":{\"key\":{\"currency\":\"USD\",\"value\":11}},\"outbound_pending\":{\"key\":{\"currency\":\"USD\",\"value\":60}}},\"country\":\"country\",\"created\":\"1970-01-12T21:42:34.472Z\",\"livemode\":true,\"status\":\"closed\",\"type\":\"other\"}"); + var options = new Stripe.V2.MoneyManagement.FinancialAccountUpdateOptions(); + var client = new StripeClient(this.Requestor); + var service = client.V2.MoneyManagement.FinancialAccounts; + Stripe.V2.MoneyManagement.FinancialAccount financialAccount = service + .Update("id_123", options); + this.AssertRequest( + HttpMethod.Post, + "/v2/money_management/financial_accounts/id_123"); + } + + [Fact] + public void TestV2MoneyManagementFinancialAccountPost3() { this.StubRequest( HttpMethod.Post, @@ -8209,7 +8302,7 @@ public void TestFeatureNotEnabledError() HttpMethod.Post, "/v2/money_management/financial_accounts", (HttpStatusCode)400, - "{\"error\":{\"type\":\"feature_not_enabled\",\"code\":\"recipient_feature_not_active\"}}"); + "{\"error\":{\"type\":\"feature_not_enabled\",\"code\":\"outbound_flow_from_closed_financial_account_unsupported\"}}"); var exception = Assert.Throws( () => {