diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 4161e81ad2..8d1f4287e9 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1058 \ No newline at end of file +v1065 \ No newline at end of file diff --git a/account.go b/account.go index f8f80cd0de..51fdd95340 100644 --- a/account.go +++ b/account.go @@ -393,6 +393,12 @@ type AccountCapabilitiesFPXPaymentsParams struct { Requested *bool `form:"requested"` } +// The gb_bank_transfer_payments capability. +type AccountCapabilitiesGBBankTransferPaymentsParams struct { + // Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays. + Requested *bool `form:"requested"` +} + // The giropay_payments capability. type AccountCapabilitiesGiropayPaymentsParams struct { // Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays. @@ -423,6 +429,12 @@ type AccountCapabilitiesJCBPaymentsParams struct { Requested *bool `form:"requested"` } +// The jp_bank_transfer_payments capability. +type AccountCapabilitiesJPBankTransferPaymentsParams struct { + // Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays. + Requested *bool `form:"requested"` +} + // The klarna_payments capability. type AccountCapabilitiesKlarnaPaymentsParams struct { // Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays. @@ -453,6 +465,12 @@ type AccountCapabilitiesMobilepayPaymentsParams struct { Requested *bool `form:"requested"` } +// The mx_bank_transfer_payments capability. +type AccountCapabilitiesMXBankTransferPaymentsParams struct { + // Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays. + Requested *bool `form:"requested"` +} + // The oxxo_payments capability. type AccountCapabilitiesOXXOPaymentsParams struct { // Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays. @@ -483,6 +501,12 @@ type AccountCapabilitiesRevolutPayPaymentsParams struct { Requested *bool `form:"requested"` } +// The sepa_bank_transfer_payments capability. +type AccountCapabilitiesSEPABankTransferPaymentsParams struct { + // Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays. + Requested *bool `form:"requested"` +} + // The sepa_debit_payments capability. type AccountCapabilitiesSEPADebitPaymentsParams struct { // Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays. @@ -531,6 +555,12 @@ type AccountCapabilitiesUSBankAccountACHPaymentsParams struct { Requested *bool `form:"requested"` } +// The us_bank_transfer_payments capability. +type AccountCapabilitiesUSBankTransferPaymentsParams struct { + // Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays. + Requested *bool `form:"requested"` +} + // The zip_payments capability. type AccountCapabilitiesZipPaymentsParams struct { // Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays. @@ -578,6 +608,8 @@ type AccountCapabilitiesParams struct { EPSPayments *AccountCapabilitiesEPSPaymentsParams `form:"eps_payments"` // The fpx_payments capability. FPXPayments *AccountCapabilitiesFPXPaymentsParams `form:"fpx_payments"` + // The gb_bank_transfer_payments capability. + GBBankTransferPayments *AccountCapabilitiesGBBankTransferPaymentsParams `form:"gb_bank_transfer_payments"` // The giropay_payments capability. GiropayPayments *AccountCapabilitiesGiropayPaymentsParams `form:"giropay_payments"` // The grabpay_payments capability. @@ -588,6 +620,8 @@ type AccountCapabilitiesParams struct { IndiaInternationalPayments *AccountCapabilitiesIndiaInternationalPaymentsParams `form:"india_international_payments"` // The jcb_payments capability. JCBPayments *AccountCapabilitiesJCBPaymentsParams `form:"jcb_payments"` + // The jp_bank_transfer_payments capability. + JPBankTransferPayments *AccountCapabilitiesJPBankTransferPaymentsParams `form:"jp_bank_transfer_payments"` // The klarna_payments capability. KlarnaPayments *AccountCapabilitiesKlarnaPaymentsParams `form:"klarna_payments"` // The konbini_payments capability. @@ -598,6 +632,8 @@ type AccountCapabilitiesParams struct { LinkPayments *AccountCapabilitiesLinkPaymentsParams `form:"link_payments"` // The mobilepay_payments capability. MobilepayPayments *AccountCapabilitiesMobilepayPaymentsParams `form:"mobilepay_payments"` + // The mx_bank_transfer_payments capability. + MXBankTransferPayments *AccountCapabilitiesMXBankTransferPaymentsParams `form:"mx_bank_transfer_payments"` // The oxxo_payments capability. OXXOPayments *AccountCapabilitiesOXXOPaymentsParams `form:"oxxo_payments"` // The p24_payments capability. @@ -608,6 +644,8 @@ type AccountCapabilitiesParams struct { PromptPayPayments *AccountCapabilitiesPromptPayPaymentsParams `form:"promptpay_payments"` // The revolut_pay_payments capability. RevolutPayPayments *AccountCapabilitiesRevolutPayPaymentsParams `form:"revolut_pay_payments"` + // The sepa_bank_transfer_payments capability. + SEPABankTransferPayments *AccountCapabilitiesSEPABankTransferPaymentsParams `form:"sepa_bank_transfer_payments"` // The sepa_debit_payments capability. SEPADebitPayments *AccountCapabilitiesSEPADebitPaymentsParams `form:"sepa_debit_payments"` // The sofort_payments capability. @@ -624,6 +662,8 @@ type AccountCapabilitiesParams struct { Treasury *AccountCapabilitiesTreasuryParams `form:"treasury"` // The us_bank_account_ach_payments capability. USBankAccountACHPayments *AccountCapabilitiesUSBankAccountACHPaymentsParams `form:"us_bank_account_ach_payments"` + // The us_bank_transfer_payments capability. + USBankTransferPayments *AccountCapabilitiesUSBankTransferPaymentsParams `form:"us_bank_transfer_payments"` // The zip_payments capability. ZipPayments *AccountCapabilitiesZipPaymentsParams `form:"zip_payments"` } @@ -1109,6 +1149,8 @@ type AccountCapabilities struct { EPSPayments AccountCapabilityStatus `json:"eps_payments"` // The status of the FPX payments capability of the account, or whether the account can directly process FPX charges. FPXPayments AccountCapabilityStatus `json:"fpx_payments"` + // The status of the GB customer_balance payments (GBP currency) capability of the account, or whether the account can directly process GB customer_balance charges. + GBBankTransferPayments AccountCapabilityStatus `json:"gb_bank_transfer_payments"` // The status of the giropay payments capability of the account, or whether the account can directly process giropay charges. GiropayPayments AccountCapabilityStatus `json:"giropay_payments"` // The status of the GrabPay payments capability of the account, or whether the account can directly process GrabPay charges. @@ -1119,6 +1161,8 @@ type AccountCapabilities struct { IndiaInternationalPayments AccountCapabilityStatus `json:"india_international_payments"` // The status of the JCB payments capability of the account, or whether the account (Japan only) can directly process JCB credit card charges in JPY currency. JCBPayments AccountCapabilityStatus `json:"jcb_payments"` + // The status of the Japanese customer_balance payments (JPY currency) capability of the account, or whether the account can directly process Japanese customer_balance charges. + JPBankTransferPayments AccountCapabilityStatus `json:"jp_bank_transfer_payments"` // The status of the Klarna payments capability of the account, or whether the account can directly process Klarna charges. KlarnaPayments AccountCapabilityStatus `json:"klarna_payments"` // The status of the konbini payments capability of the account, or whether the account can directly process konbini charges. @@ -1129,6 +1173,8 @@ type AccountCapabilities struct { LinkPayments AccountCapabilityStatus `json:"link_payments"` // The status of the MobilePay capability of the account, or whether the account can directly process MobilePay charges. MobilepayPayments AccountCapabilityStatus `json:"mobilepay_payments"` + // The status of the Mexican customer_balance payments (MXN currency) capability of the account, or whether the account can directly process Mexican customer_balance charges. + MXBankTransferPayments AccountCapabilityStatus `json:"mx_bank_transfer_payments"` // The status of the OXXO payments capability of the account, or whether the account can directly process OXXO charges. OXXOPayments AccountCapabilityStatus `json:"oxxo_payments"` // The status of the P24 payments capability of the account, or whether the account can directly process P24 charges. @@ -1139,6 +1185,8 @@ type AccountCapabilities struct { PromptPayPayments AccountCapabilityStatus `json:"promptpay_payments"` // The status of the RevolutPay capability of the account, or whether the account can directly process RevolutPay payments. RevolutPayPayments AccountCapabilityStatus `json:"revolut_pay_payments"` + // The status of the SEPA customer_balance payments (EUR currency) capability of the account, or whether the account can directly process SEPA customer_balance charges. + SEPABankTransferPayments AccountCapabilityStatus `json:"sepa_bank_transfer_payments"` // The status of the SEPA Direct Debits payments capability of the account, or whether the account can directly process SEPA Direct Debits charges. SEPADebitPayments AccountCapabilityStatus `json:"sepa_debit_payments"` // The status of the Sofort payments capability of the account, or whether the account can directly process Sofort charges. @@ -1155,6 +1203,8 @@ type AccountCapabilities struct { Treasury AccountCapabilityStatus `json:"treasury"` // The status of the US bank account ACH payments capability of the account, or whether the account can directly process US bank account charges. USBankAccountACHPayments AccountCapabilityStatus `json:"us_bank_account_ach_payments"` + // The status of the US customer_balance payments (USD currency) capability of the account, or whether the account can directly process US customer_balance charges. + USBankTransferPayments AccountCapabilityStatus `json:"us_bank_transfer_payments"` // The status of the Zip capability of the account, or whether the account can directly process Zip charges. ZipPayments AccountCapabilityStatus `json:"zip_payments"` } diff --git a/checkout_session.go b/checkout_session.go index f37136963d..efc0d83b18 100644 --- a/checkout_session.go +++ b/checkout_session.go @@ -2890,7 +2890,7 @@ type CheckoutSession struct { Mode CheckoutSessionMode `json:"mode"` // String representing the object's type. Objects of the same type share the same value. Object string `json:"object"` - // The ID of the PaymentIntent for Checkout Sessions in `payment` mode. + // The ID of the PaymentIntent for Checkout Sessions in `payment` mode. You can't confirm or cancel the PaymentIntent for a Checkout Session. To cancel, [expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead. PaymentIntent *PaymentIntent `json:"payment_intent"` // The ID of the Payment Link that created this Session. PaymentLink *PaymentLink `json:"payment_link"` @@ -2915,7 +2915,7 @@ type CheckoutSession struct { ReturnURL string `json:"return_url"` // Controls saved payment method settings for the session. Only available in `payment` and `subscription` mode. SavedPaymentMethodOptions *CheckoutSessionSavedPaymentMethodOptions `json:"saved_payment_method_options"` - // The ID of the SetupIntent for Checkout Sessions in `setup` mode. + // The ID of the SetupIntent for Checkout Sessions in `setup` mode. You can't confirm or cancel the SetupIntent for a Checkout Session. To cancel, [expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead. SetupIntent *SetupIntent `json:"setup_intent"` // When set, provides configuration for Checkout to collect a shipping address from a customer. ShippingAddressCollection *CheckoutSessionShippingAddressCollection `json:"shipping_address_collection"` diff --git a/climate/order/client.go b/climate/order/client.go index 52454e5c1d..78271078bc 100644 --- a/climate/order/client.go +++ b/climate/order/client.go @@ -60,7 +60,7 @@ func (c Client) Update(id string, params *stripe.ClimateOrderParams) (*stripe.Cl return order, err } -// Cancels a Climate order. You can cancel an order within 30 days of creation. Stripe refunds the +// Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the // reservation amount_subtotal, but not the amount_fees for user-triggered cancellations. Frontier // might cancel reservations if suppliers fail to deliver. If Frontier cancels the reservation, Stripe // provides 90 days advance notice and refunds the amount_total. @@ -68,7 +68,7 @@ func Cancel(id string, params *stripe.ClimateOrderCancelParams) (*stripe.Climate return getC().Cancel(id, params) } -// Cancels a Climate order. You can cancel an order within 30 days of creation. Stripe refunds the +// Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the // reservation amount_subtotal, but not the amount_fees for user-triggered cancellations. Frontier // might cancel reservations if suppliers fail to deliver. If Frontier cancels the reservation, Stripe // provides 90 days advance notice and refunds the amount_total. diff --git a/climate_order.go b/climate_order.go index dde8dfd320..3fb9867c80 100644 --- a/climate_order.go +++ b/climate_order.go @@ -81,7 +81,7 @@ func (p *ClimateOrderParams) AddMetadata(key string, value string) { p.Metadata[key] = value } -// Cancels a Climate order. You can cancel an order within 30 days of creation. Stripe refunds the +// Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the // reservation amount_subtotal, but not the amount_fees for user-triggered cancellations. Frontier // might cancel reservations if suppliers fail to deliver. If Frontier cancels the reservation, Stripe // provides 90 days advance notice and refunds the amount_total. diff --git a/invoice.go b/invoice.go index 17fa4a6a67..5166e4d2fd 100644 --- a/invoice.go +++ b/invoice.go @@ -171,6 +171,7 @@ const ( InvoicePaymentSettingsPaymentMethodTypeSEPACreditTransfer InvoicePaymentSettingsPaymentMethodType = "sepa_credit_transfer" InvoicePaymentSettingsPaymentMethodTypeSEPADebit InvoicePaymentSettingsPaymentMethodType = "sepa_debit" InvoicePaymentSettingsPaymentMethodTypeSofort InvoicePaymentSettingsPaymentMethodType = "sofort" + InvoicePaymentSettingsPaymentMethodTypeSwish InvoicePaymentSettingsPaymentMethodType = "swish" InvoicePaymentSettingsPaymentMethodTypeUSBankAccount InvoicePaymentSettingsPaymentMethodType = "us_bank_account" InvoicePaymentSettingsPaymentMethodTypeWeChatPay InvoicePaymentSettingsPaymentMethodType = "wechat_pay" ) diff --git a/setupintent.go b/setupintent.go index 126acd3084..0cd4cddba5 100644 --- a/setupintent.go +++ b/setupintent.go @@ -855,7 +855,7 @@ func (p *SetupIntentParams) AddMetadata(key string, value string) { // You can cancel a SetupIntent object when it's in one of these statuses: requires_payment_method, requires_confirmation, or requires_action. // -// After you cancel it, setup is abandoned and any operations on the SetupIntent fail with an error. +// After you cancel it, setup is abandoned and any operations on the SetupIntent fail with an error. You can't cancel the SetupIntent for a Checkout Session. [Expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead. type SetupIntentCancelParams struct { Params `form:"*"` // Reason for canceling this SetupIntent. Possible values are: `abandoned`, `requested_by_customer`, or `duplicate` diff --git a/setupintent/client.go b/setupintent/client.go index c9baad4ce8..d9f0e8160f 100644 --- a/setupintent/client.go +++ b/setupintent/client.go @@ -80,14 +80,14 @@ func (c Client) Update(id string, params *stripe.SetupIntentParams) (*stripe.Set // You can cancel a SetupIntent object when it's in one of these statuses: requires_payment_method, requires_confirmation, or requires_action. // -// After you cancel it, setup is abandoned and any operations on the SetupIntent fail with an error. +// After you cancel it, setup is abandoned and any operations on the SetupIntent fail with an error. You can't cancel the SetupIntent for a Checkout Session. [Expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead. func Cancel(id string, params *stripe.SetupIntentCancelParams) (*stripe.SetupIntent, error) { return getC().Cancel(id, params) } // You can cancel a SetupIntent object when it's in one of these statuses: requires_payment_method, requires_confirmation, or requires_action. // -// After you cancel it, setup is abandoned and any operations on the SetupIntent fail with an error. +// After you cancel it, setup is abandoned and any operations on the SetupIntent fail with an error. You can't cancel the SetupIntent for a Checkout Session. [Expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead. func (c Client) Cancel(id string, params *stripe.SetupIntentCancelParams) (*stripe.SetupIntent, error) { path := stripe.FormatURLPath("/v1/setup_intents/%s/cancel", id) setupintent := &stripe.SetupIntent{} diff --git a/subscription.go b/subscription.go index 3f83ee4dc2..6a36c12b84 100644 --- a/subscription.go +++ b/subscription.go @@ -190,6 +190,7 @@ const ( SubscriptionPaymentSettingsPaymentMethodTypeSEPACreditTransfer SubscriptionPaymentSettingsPaymentMethodType = "sepa_credit_transfer" SubscriptionPaymentSettingsPaymentMethodTypeSEPADebit SubscriptionPaymentSettingsPaymentMethodType = "sepa_debit" SubscriptionPaymentSettingsPaymentMethodTypeSofort SubscriptionPaymentSettingsPaymentMethodType = "sofort" + SubscriptionPaymentSettingsPaymentMethodTypeSwish SubscriptionPaymentSettingsPaymentMethodType = "swish" SubscriptionPaymentSettingsPaymentMethodTypeUSBankAccount SubscriptionPaymentSettingsPaymentMethodType = "us_bank_account" SubscriptionPaymentSettingsPaymentMethodTypeWeChatPay SubscriptionPaymentSettingsPaymentMethodType = "wechat_pay" ) diff --git a/tax/transaction/client.go b/tax/transaction/client.go index bf54bca4a1..a37233aa2a 100644 --- a/tax/transaction/client.go +++ b/tax/transaction/client.go @@ -33,12 +33,12 @@ func (c Client) Get(id string, params *stripe.TaxTransactionParams) (*stripe.Tax return transaction, err } -// Creates a Tax Transaction from a calculation. +// Creates a Tax Transaction from a calculation, if that calculation hasn't expired. Calculations expire after 90 days. func CreateFromCalculation(params *stripe.TaxTransactionCreateFromCalculationParams) (*stripe.TaxTransaction, error) { return getC().CreateFromCalculation(params) } -// Creates a Tax Transaction from a calculation. +// Creates a Tax Transaction from a calculation, if that calculation hasn't expired. Calculations expire after 90 days. func (c Client) CreateFromCalculation(params *stripe.TaxTransactionCreateFromCalculationParams) (*stripe.TaxTransaction, error) { transaction := &stripe.TaxTransaction{} err := c.B.Call( diff --git a/tax_transaction.go b/tax_transaction.go index a818dde6ef..c081556a15 100644 --- a/tax_transaction.go +++ b/tax_transaction.go @@ -209,7 +209,7 @@ func (p *TaxTransactionListLineItemsParams) AddExpand(f string) { p.Expand = append(p.Expand, &f) } -// Creates a Tax Transaction from a calculation. +// Creates a Tax Transaction from a calculation, if that calculation hasn't expired. Calculations expire after 90 days. type TaxTransactionCreateFromCalculationParams struct { Params `form:"*"` // Tax Calculation ID to be used as input when creating the transaction.