diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index f780889d14..d827e3144c 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v358 \ No newline at end of file +v368 \ No newline at end of file diff --git a/api_version.go b/api_version.go index 23244a9a0f..63055410c5 100644 --- a/api_version.go +++ b/api_version.go @@ -8,5 +8,5 @@ package stripe const ( apiVersion string = "2022-11-15" - previewVersion string = "20230519T204128" + previewVersion string = "2023-05-26.preview-v2" ) diff --git a/checkout_session.go b/checkout_session.go index 3569c83633..8b2ac980f9 100644 --- a/checkout_session.go +++ b/checkout_session.go @@ -351,14 +351,16 @@ type CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddr // List of values that CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType can take const ( + CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeAba CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "aba" CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeIBAN CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "iban" CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeSEPA CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "sepa" CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeSortCode CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "sort_code" CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeSpei CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "spei" + CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeSwift CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "swift" CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeZengin CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "zengin" ) -// The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. +// The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`. type CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferType string // List of values that CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferType can take @@ -367,6 +369,7 @@ const ( CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferTypeGBBankTransfer CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferType = "gb_bank_transfer" CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferTypeJPBankTransfer CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferType = "jp_bank_transfer" CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferTypeMXBankTransfer CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferType = "mx_bank_transfer" + CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferTypeUSBankTransfer CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferType = "us_bank_transfer" ) // The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`. @@ -2016,7 +2019,7 @@ type CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransfer struct { // // Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`. RequestedAddressTypes []CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType `json:"requested_address_types"` - // The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. + // The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`. Type CheckoutSessionPaymentMethodOptionsCustomerBalanceBankTransferType `json:"type"` } type CheckoutSessionPaymentMethodOptionsCustomerBalance struct { diff --git a/customercashbalancetransaction.go b/customercashbalancetransaction.go index 21eb43cc26..3b9db3f256 100644 --- a/customercashbalancetransaction.go +++ b/customercashbalancetransaction.go @@ -6,7 +6,7 @@ package stripe -// The funding method type used to fund the customer balance. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. +// The funding method type used to fund the customer balance. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`. type CustomerCashBalanceTransactionFundedBankTransferType string // List of values that CustomerCashBalanceTransactionFundedBankTransferType can take @@ -15,6 +15,17 @@ const ( CustomerCashBalanceTransactionFundedBankTransferTypeGBBankTransfer CustomerCashBalanceTransactionFundedBankTransferType = "gb_bank_transfer" CustomerCashBalanceTransactionFundedBankTransferTypeJPBankTransfer CustomerCashBalanceTransactionFundedBankTransferType = "jp_bank_transfer" CustomerCashBalanceTransactionFundedBankTransferTypeMXBankTransfer CustomerCashBalanceTransactionFundedBankTransferType = "mx_bank_transfer" + CustomerCashBalanceTransactionFundedBankTransferTypeUSBankTransfer CustomerCashBalanceTransactionFundedBankTransferType = "us_bank_transfer" +) + +// The banking network used for this funding. +type CustomerCashBalanceTransactionFundedBankTransferUSBankTransferNetwork string + +// List of values that CustomerCashBalanceTransactionFundedBankTransferUSBankTransferNetwork can take +const ( + CustomerCashBalanceTransactionFundedBankTransferUSBankTransferNetworkACH CustomerCashBalanceTransactionFundedBankTransferUSBankTransferNetwork = "ach" + CustomerCashBalanceTransactionFundedBankTransferUSBankTransferNetworkDomesticWireUS CustomerCashBalanceTransactionFundedBankTransferUSBankTransferNetwork = "domestic_wire_us" + CustomerCashBalanceTransactionFundedBankTransferUSBankTransferNetworkSwift CustomerCashBalanceTransactionFundedBankTransferUSBankTransferNetwork = "swift" ) // The type of the cash balance transaction. One of `applied_to_payment`, `unapplied_from_payment`, `refunded_from_payment`, `funded`, `return_initiated`, or `return_canceled`. New types may be added in future. See [Customer Balance](https://stripe.com/docs/payments/customer-balance#types) to learn more about these types. @@ -70,14 +81,21 @@ type CustomerCashBalanceTransactionFundedBankTransferJPBankTransfer struct { // The full name of the sender, as supplied by the sending bank. SenderName string `json:"sender_name"` } +type CustomerCashBalanceTransactionFundedBankTransferUSBankTransfer struct { + // The banking network used for this funding. + Network CustomerCashBalanceTransactionFundedBankTransferUSBankTransferNetwork `json:"network"` + // The full name of the sender, as supplied by the sending bank. + SenderName string `json:"sender_name"` +} type CustomerCashBalanceTransactionFundedBankTransfer struct { EUBankTransfer *CustomerCashBalanceTransactionFundedBankTransferEUBankTransfer `json:"eu_bank_transfer"` GBBankTransfer *CustomerCashBalanceTransactionFundedBankTransferGBBankTransfer `json:"gb_bank_transfer"` JPBankTransfer *CustomerCashBalanceTransactionFundedBankTransferJPBankTransfer `json:"jp_bank_transfer"` // The user-supplied reference field on the bank transfer. Reference string `json:"reference"` - // The funding method type used to fund the customer balance. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. - Type CustomerCashBalanceTransactionFundedBankTransferType `json:"type"` + // The funding method type used to fund the customer balance. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`. + Type CustomerCashBalanceTransactionFundedBankTransferType `json:"type"` + USBankTransfer *CustomerCashBalanceTransactionFundedBankTransferUSBankTransfer `json:"us_bank_transfer"` } type CustomerCashBalanceTransactionFunded struct { BankTransfer *CustomerCashBalanceTransactionFundedBankTransfer `json:"bank_transfer"` diff --git a/invoice.go b/invoice.go index 60c20ab724..eb9dbb4373 100644 --- a/invoice.go +++ b/invoice.go @@ -191,6 +191,16 @@ const ( InvoiceStatusVoid InvoiceStatus = "void" ) +// The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. +type InvoiceSubscriptionDetailsPauseCollectionBehavior string + +// List of values that InvoiceSubscriptionDetailsPauseCollectionBehavior can take +const ( + InvoiceSubscriptionDetailsPauseCollectionBehaviorKeepAsDraft InvoiceSubscriptionDetailsPauseCollectionBehavior = "keep_as_draft" + InvoiceSubscriptionDetailsPauseCollectionBehaviorMarkUncollectible InvoiceSubscriptionDetailsPauseCollectionBehavior = "mark_uncollectible" + InvoiceSubscriptionDetailsPauseCollectionBehaviorVoid InvoiceSubscriptionDetailsPauseCollectionBehavior = "void" +) + // The reasoning behind this tax, for example, if the product is tax exempt. The possible values for this field may be extended as new tax rules are supported. type InvoiceTotalTaxAmountTaxabilityReason string @@ -223,39 +233,55 @@ type InvoiceSearchParams struct { Page *string `form:"page"` } -// You can list all invoices, or list the invoices for a specific customer. The invoices are returned sorted by creation date, with the most recently created invoices appearing first. -type InvoiceListParams struct { - ListParams `form:"*"` - // The collection method of the invoice to retrieve. Either `charge_automatically` or `send_invoice`. - CollectionMethod *string `form:"collection_method"` - Created *int64 `form:"created"` - CreatedRange *RangeQueryParams `form:"created"` - // Only return invoices for the customer specified by this customer ID. - Customer *string `form:"customer"` - DueDate *int64 `form:"due_date"` - DueDateRange *RangeQueryParams `form:"due_date"` - // The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview) - Status *string `form:"status"` - // Only return invoices for the subscription specified by this subscription ID. - Subscription *string `form:"subscription"` -} - -// Settings for automatic tax lookup for this invoice. +// Settings for automatic tax lookup for this invoice preview. type InvoiceAutomaticTaxParams struct { // Whether Stripe automatically computes tax on this invoice. Note that incompatible invoice items (invoice items with manually specified [tax rates](https://stripe.com/docs/api/tax_rates), negative amounts, or `tax_behavior=unspecified`) cannot be added to automatic tax invoices. Enabled *bool `form:"enabled"` } +type InvoiceUpcomingAutomaticTaxParams struct { + Enabled *bool `form:"enabled"` +} -// A list of up to 4 custom fields to be displayed on the invoice. -type InvoiceCustomFieldParams struct { - // The name of the custom field. This may be up to 30 characters. +// The customer's shipping information. Appears on invoices emailed to this customer. +type InvoiceUpcomingCustomerDetailsShippingParams struct { + // Customer shipping address. + Address *AddressParams `form:"address"` + // Customer name. Name *string `form:"name"` - // The value of the custom field. This may be up to 30 characters. + // Customer phone (including extension). + Phone *string `form:"phone"` +} + +// Tax details about the customer. +type InvoiceUpcomingCustomerDetailsTaxParams struct { + // A recent IP address of the customer used for tax reporting and tax location inference. Stripe recommends updating the IP address when a new PaymentMethod is attached or the address field on the customer is updated. We recommend against updating this field more frequently since it could result in unexpected tax location/reporting outcomes. + IPAddress *string `form:"ip_address"` +} + +// The customer's tax IDs. +type InvoiceUpcomingCustomerDetailsTaxIDParams struct { + // Type of the tax ID, one of `ae_trn`, `au_abn`, `au_arn`, `bg_uic`, `br_cnpj`, `br_cpf`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `ch_vat`, `cl_tin`, `eg_tin`, `es_cif`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `hk_br`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kr_brn`, `li_uid`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ph_tin`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `th_vat`, `tr_tin`, `tw_vat`, `ua_vat`, `us_ein`, or `za_vat` + Type *string `form:"type"` + // Value of the tax ID. Value *string `form:"value"` } +// Details about the customer you want to invoice or overrides for an existing customer. +type InvoiceUpcomingCustomerDetailsParams struct { + // The customer's address. + Address *AddressParams `form:"address"` + // The customer's shipping information. Appears on invoices emailed to this customer. + Shipping *InvoiceUpcomingCustomerDetailsShippingParams `form:"shipping"` + // Tax details about the customer. + Tax *InvoiceUpcomingCustomerDetailsTaxParams `form:"tax"` + // The customer's tax exemption. One of `none`, `exempt`, or `reverse`. + TaxExempt *string `form:"tax_exempt"` + // The customer's tax IDs. + TaxIDs []*InvoiceUpcomingCustomerDetailsTaxIDParams `form:"tax_ids"` +} + // Time span for the redeemed discount. -type InvoiceDiscountDiscountEndDurationParams struct { +type InvoiceUpcomingDiscountDiscountEndDurationParams struct { // Specifies a type of interval unit. Either `day`, `week`, `month` or `year`. Interval *string `form:"interval"` // The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration. @@ -267,14 +293,14 @@ type InvoiceDiscountDiscountEndParams struct { // Time span for the redeemed discount. Duration *InvoiceDiscountDiscountEndDurationParams `form:"duration"` // Time span for the redeemed discount. - DurationTODOINCOMPATIBLECOMBINATION *InvoiceDiscountDiscountEndDurationParams `form:"durationTODO_INCOMPATIBLE_COMBINATION"` + DurationTODOINCOMPATIBLECOMBINATION *InvoiceUpcomingDiscountDiscountEndDurationParams `form:"durationTODO_INCOMPATIBLE_COMBINATION"` // A precise Unix timestamp for the discount to end. Must be in the future. Timestamp *int64 `form:"timestamp"` // The type of calculation made to determine when the discount ends. Type *string `form:"type"` } -// The coupons to redeem into discounts for the invoice. If not specified, inherits the discount from the invoice's customer. Pass an empty string to avoid inheriting any discounts. +// The coupons to redeem into discounts for the invoice preview. If not specified, inherits the discount from the customer or subscription. This only works for coupons directly applied to the invoice. To apply a coupon to a subscription, you must use the `coupon` parameter instead. Pass an empty string to avoid inheriting any discounts. To preview the upcoming invoice for a subscription that hasn't been created, use `coupon` instead. type InvoiceDiscountParams struct { // ID of the coupon to create a new discount for. Coupon *string `form:"coupon"` @@ -284,12 +310,139 @@ type InvoiceDiscountParams struct { DiscountEnd *InvoiceDiscountDiscountEndParams `form:"discount_end"` } -// Revise an existing invoice. The new invoice will be created in `status=draft`. See the [revision documentation](https://stripe.com/docs/invoicing/invoice-revisions) for more details. -type InvoiceFromInvoiceParams struct { - // The relation between the new invoice and the original invoice. Currently, only 'revision' is permitted - Action *string `form:"action"` - // The `id` of the invoice that will be cloned. - Invoice *string `form:"invoice"` +// The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details. +type InvoiceUpcomingInvoiceItemPeriodParams struct { + // The end of the period, which must be greater than or equal to the start. This value is inclusive. + End *int64 `form:"end"` + // The start of the period. This value is inclusive. + Start *int64 `form:"start"` +} + +// List of invoice items to add or update in the upcoming invoice preview. +type InvoiceUpcomingInvoiceItemParams struct { + // The integer amount in cents (or local equivalent) of previewed invoice item. + Amount *int64 `form:"amount"` + // Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Only applicable to new invoice items. + Currency *string `form:"currency"` + // An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking. + Description *string `form:"description"` + // Explicitly controls whether discounts apply to this invoice item. Defaults to true, except for negative invoice items. + Discountable *bool `form:"discountable"` + // The coupons to redeem into discounts for the invoice item in the preview. + Discounts []*InvoiceItemDiscountParams `form:"discounts"` + // The ID of the invoice item to update in preview. If not specified, a new invoice item will be added to the preview of the upcoming invoice. + InvoiceItem *string `form:"invoiceitem"` + // Set of [key-value pairs](https://stripe.com/docs/api/metadata) 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`. + Metadata map[string]string `form:"metadata"` + // The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details. + Period *InvoiceUpcomingInvoiceItemPeriodParams `form:"period"` + // The ID of the price object. + Price *string `form:"price"` + // Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. + PriceData *InvoiceItemPriceDataParams `form:"price_data"` + // Non-negative integer. The quantity of units for the invoice item. + Quantity *int64 `form:"quantity"` + // Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. + TaxBehavior *string `form:"tax_behavior"` + // A [tax code](https://stripe.com/docs/tax/tax-categories) ID. + TaxCode *string `form:"tax_code"` + // The tax rates that apply to the item. When set, any `default_tax_rates` do not apply to this item. + TaxRates []*string `form:"tax_rates"` + // The integer unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This unit_amount will be multiplied by the quantity to get the full amount. If you want to apply a credit to the customer's account, pass a negative unit_amount. + UnitAmount *int64 `form:"unit_amount"` + // Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set. + UnitAmountDecimal *float64 `form:"unit_amount_decimal,high_precision"` +} + +// The pre-billing to apply to the subscription as a preview. +type InvoiceUpcomingSubscriptionPrebillingParams struct { + // This is used to determine the number of billing cycles to prebill. + Iterations *int64 `form:"iterations"` +} + +// At any time, you can preview the upcoming invoice for a customer. This will show you all the charges that are pending, including subscription renewal charges, invoice item charges, etc. It will also show you any discounts that are applicable to the invoice. +// +// Note that when you are viewing an upcoming invoice, you are simply viewing a preview – the invoice has not yet been created. As such, the upcoming invoice will not show up in invoice listing calls, and you cannot use the API to pay or edit the invoice. If you want to change the amount that your customer will be billed, you can add, remove, or update pending invoice items, or update the customer's discount. +// +// You can preview the effects of updating a subscription, including a preview of what proration will take place. To ensure that the actual proration is calculated exactly the same as the previewed proration, you should pass a proration_date parameter when doing the actual subscription update. The value passed in should be the same as the subscription_proration_date returned on the upcoming invoice resource. The recommended way to get only the prorations being previewed is to consider only proration line items where period[start] is equal to the subscription_proration_date on the upcoming invoice resource. +type InvoiceUpcomingParams struct { + Params `form:"*"` + // Settings for automatic tax lookup for this invoice preview. + AutomaticTax *InvoiceAutomaticTaxParams `form:"automatic_tax"` + // The code of the coupon to apply. If `subscription` or `subscription_items` is provided, the invoice returned will preview updating or creating a subscription with that coupon. Otherwise, it will preview applying that coupon to the customer for the next upcoming invoice from among the customer's subscriptions. The invoice can be previewed without a coupon by passing this value as an empty string. + Coupon *string `form:"coupon"` + // The currency to preview this invoice in. Defaults to that of `customer` if not specified. + Currency *string `form:"currency"` + // The identifier of the customer whose upcoming invoice you'd like to retrieve. + Customer *string `form:"customer"` + // Details about the customer you want to invoice or overrides for an existing customer. + CustomerDetails *InvoiceUpcomingCustomerDetailsParams `form:"customer_details"` + // The coupons to redeem into discounts for the invoice preview. If not specified, inherits the discount from the customer or subscription. This only works for coupons directly applied to the invoice. To apply a coupon to a subscription, you must use the `coupon` parameter instead. Pass an empty string to avoid inheriting any discounts. To preview the upcoming invoice for a subscription that hasn't been created, use `coupon` instead. + Discounts []*InvoiceDiscountParams `form:"discounts"` + // List of invoice items to add or update in the upcoming invoice preview. + InvoiceItems []*InvoiceUpcomingInvoiceItemParams `form:"invoice_items"` + // The identifier of the unstarted schedule whose upcoming invoice you'd like to retrieve. Cannot be used with subscription or subscription fields. + Schedule *string `form:"schedule"` + // The identifier of the subscription for which you'd like to retrieve the upcoming invoice. If not provided, but a `subscription_items` is provided, you will preview creating a subscription with those items. If neither `subscription` nor `subscription_items` is provided, you will retrieve the next upcoming invoice from among the customer's subscriptions. + Subscription *string `form:"subscription"` + // For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`. + SubscriptionBillingCycleAnchor *int64 `form:"subscription_billing_cycle_anchor"` + SubscriptionBillingCycleAnchorNow *bool `form:"-"` // See custom AppendTo + SubscriptionBillingCycleAnchorUnchanged *bool `form:"-"` // See custom AppendTo + // Timestamp indicating when the subscription should be scheduled to cancel. Will prorate if within the current period and prorations have been enabled using `proration_behavior`. + SubscriptionCancelAt *int64 `form:"subscription_cancel_at"` + // Boolean indicating whether this subscription should cancel at the end of the current period. + SubscriptionCancelAtPeriodEnd *bool `form:"subscription_cancel_at_period_end"` + // This simulates the subscription being canceled or expired immediately. + SubscriptionCancelNow *bool `form:"subscription_cancel_now"` + // If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set. + SubscriptionDefaultTaxRates []*string `form:"subscription_default_tax_rates"` + // A list of up to 20 subscription items, each with an attached price. + SubscriptionItems []*SubscriptionItemsParams `form:"subscription_items"` + // The pre-billing to apply to the subscription as a preview. + SubscriptionPrebilling *InvoiceUpcomingSubscriptionPrebillingParams `form:"subscription_prebilling"` + // Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`. + SubscriptionProrationBehavior *string `form:"subscription_proration_behavior"` + // If previewing an update to a subscription, and doing proration, `subscription_proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period and within the current phase of the schedule backing this subscription, if the schedule exists. If set, `subscription`, and one of `subscription_items`, or `subscription_trial_end` are required. Also, `subscription_proration_behavior` cannot be set to 'none'. + SubscriptionProrationDate *int64 `form:"subscription_proration_date"` + // For paused subscriptions, setting `subscription_resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed. + SubscriptionResumeAt *string `form:"subscription_resume_at"` + // Date a subscription is intended to start (can be future or past) + SubscriptionStartDate *int64 `form:"subscription_start_date"` + // If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_items` or `subscription` is required. + SubscriptionTrialEnd *int64 `form:"subscription_trial_end"` + SubscriptionTrialEndNow *bool `form:"-"` // See custom AppendTo + // Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `subscription_trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `subscription_trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more. + SubscriptionTrialFromPlan *bool `form:"subscription_trial_from_plan"` +} + +// AppendTo implements custom encoding logic for InvoiceUpcomingParams. +func (i *InvoiceUpcomingParams) AppendTo(body *form.Values, keyParts []string) { + if BoolValue(i.SubscriptionBillingCycleAnchorNow) { + body.Add(form.FormatKey(append(keyParts, "subscription_billing_cycle_anchor")), "now") + } + if BoolValue(i.SubscriptionBillingCycleAnchorUnchanged) { + body.Add(form.FormatKey(append(keyParts, "subscription_billing_cycle_anchor")), "unchanged") + } + if BoolValue(i.SubscriptionTrialEndNow) { + body.Add(form.FormatKey(append(keyParts, "subscription_trial_end")), "now") + } +} + +// A list of up to 4 custom fields to be displayed on the invoice. If a value for `custom_fields` is specified, the list specified will replace the existing custom field list on this invoice. Pass an empty string to remove previously-defined fields. +type InvoiceCustomFieldParams struct { + // The name of the custom field. This may be up to 30 characters. + Name *string `form:"name"` + // The value of the custom field. This may be up to 30 characters. + Value *string `form:"value"` +} + +// Time span for the redeemed discount. +type InvoiceDiscountDiscountEndDurationParams struct { + // Specifies a type of interval unit. Either `day`, `week`, `month` or `year`. + Interval *string `form:"interval"` + // The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration. + IntervalCount *int64 `form:"interval_count"` } // Additional fields for Mandate creation @@ -354,7 +507,7 @@ type InvoicePaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEUBank type InvoicePaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferParams struct { // Configuration for eu_bank_transfer funding type. EUBankTransfer *InvoicePaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEUBankTransferParams `form:"eu_bank_transfer"` - // The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. + // The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`. Type *string `form:"type"` } @@ -495,7 +648,7 @@ type InvoiceShippingDetailsParams struct { Phone *string `form:"phone"` } -// If specified, the funds from the invoice will be transferred to the destination and the ID of the resulting transfer will be found on the invoice's charge. +// If specified, the funds from the invoice will be transferred to the destination and the ID of the resulting transfer will be found on the invoice's charge. This will be unset if you POST an empty value. type InvoiceTransferDataParams struct { // The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred. Amount *int64 `form:"amount"` @@ -503,26 +656,31 @@ type InvoiceTransferDataParams struct { Destination *string `form:"destination"` } -// This endpoint creates a draft invoice for a given customer. The invoice remains a draft until you [finalize the invoice, which allows you to [pay](#pay_invoice) or send](https://stripe.com/docs/api#finalize_invoice) the invoice to your customers. +// Draft invoices are fully editable. Once an invoice is [finalized](https://stripe.com/docs/billing/invoices/workflow#finalized), +// monetary values, as well as collection_method, become uneditable. +// +// If you would like to stop the Stripe Billing engine from automatically finalizing, reattempting payments on, +// sending reminders for, or [automatically reconciling](https://stripe.com/docs/billing/invoices/reconciliation) invoices, pass +// auto_advance=false. type InvoiceParams struct { Params `form:"*"` // The account tax IDs associated with the invoice. Only editable when the invoice is a draft. AccountTaxIDs []*string `form:"account_tax_ids"` // A fee in cents (or local equivalent) that will be applied to the invoice and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the Stripe-Account header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/billing/invoices/connect#collecting-fees). ApplicationFeeAmount *int64 `form:"application_fee_amount"` - // Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. + // Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. When `false`, the invoice's state will not automatically advance without an explicit action. AutoAdvance *bool `form:"auto_advance"` // Settings for automatic tax lookup for this invoice. AutomaticTax *InvoiceAutomaticTaxParams `form:"automatic_tax"` - // Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices. + // Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`. CollectionMethod *string `form:"collection_method"` // The currency to create this invoice in. Defaults to that of `customer` if not specified. Currency *string `form:"currency"` // The ID of the customer who will be billed. Customer *string `form:"customer"` - // A list of up to 4 custom fields to be displayed on the invoice. If a value for `custom_fields` is specified, the list specified will replace the existing custom field list on this invoice. Pass an empty string to remove previously-defined fields. + // A list of up to 4 custom fields to be displayed on the invoice. CustomFields []*InvoiceCustomFieldParams `form:"custom_fields"` - // The number of days from which the invoice is created until it is due. Only valid for invoices where `collection_method=send_invoice`. This field can only be updated on `draft` invoices. + // The number of days from when the invoice is created until it is due. Valid only for invoices where `collection_method=send_invoice`. DaysUntilDue *int64 `form:"days_until_due"` // ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings. DefaultPaymentMethod *string `form:"default_payment_method"` @@ -532,9 +690,9 @@ type InvoiceParams struct { DefaultTaxRates []*string `form:"default_tax_rates"` // An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard. Description *string `form:"description"` - // The discounts that will apply to the invoice. Pass an empty string to remove previously-defined discounts. + // The coupons to redeem into discounts for the invoice. If not specified, inherits the discount from the invoice's customer. Pass an empty string to avoid inheriting any discounts. Discounts []*InvoiceDiscountParams `form:"discounts"` - // The date on which payment for this invoice is due. Only valid for invoices where `collection_method=send_invoice`. This field can only be updated on `draft` invoices. + // The date on which payment for this invoice is due. Valid only for invoices where `collection_method=send_invoice`. DueDate *int64 `form:"due_date"` // Footer to be displayed on the invoice. Footer *string `form:"footer"` @@ -559,174 +717,6 @@ type InvoiceParams struct { // If specified, the funds from the invoice will be transferred to the destination and the ID of the resulting transfer will be found on the invoice's charge. This will be unset if you POST an empty value. TransferData *InvoiceTransferDataParams `form:"transfer_data"` } -type InvoiceUpcomingAutomaticTaxParams struct { - Enabled *bool `form:"enabled"` -} - -// The customer's shipping information. Appears on invoices emailed to this customer. -type InvoiceUpcomingCustomerDetailsShippingParams struct { - // Customer shipping address. - Address *AddressParams `form:"address"` - // Customer name. - Name *string `form:"name"` - // Customer phone (including extension). - Phone *string `form:"phone"` -} - -// Tax details about the customer. -type InvoiceUpcomingCustomerDetailsTaxParams struct { - // A recent IP address of the customer used for tax reporting and tax location inference. Stripe recommends updating the IP address when a new PaymentMethod is attached or the address field on the customer is updated. We recommend against updating this field more frequently since it could result in unexpected tax location/reporting outcomes. - IPAddress *string `form:"ip_address"` -} - -// The customer's tax IDs. -type InvoiceUpcomingCustomerDetailsTaxIDParams struct { - // Type of the tax ID, one of `ae_trn`, `au_abn`, `au_arn`, `bg_uic`, `br_cnpj`, `br_cpf`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `ch_vat`, `cl_tin`, `eg_tin`, `es_cif`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `hk_br`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kr_brn`, `li_uid`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ph_tin`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `th_vat`, `tr_tin`, `tw_vat`, `ua_vat`, `us_ein`, or `za_vat` - Type *string `form:"type"` - // Value of the tax ID. - Value *string `form:"value"` -} - -// Details about the customer you want to invoice or overrides for an existing customer. -type InvoiceUpcomingCustomerDetailsParams struct { - // The customer's address. - Address *AddressParams `form:"address"` - // The customer's shipping information. Appears on invoices emailed to this customer. - Shipping *InvoiceUpcomingCustomerDetailsShippingParams `form:"shipping"` - // Tax details about the customer. - Tax *InvoiceUpcomingCustomerDetailsTaxParams `form:"tax"` - // The customer's tax exemption. One of `none`, `exempt`, or `reverse`. - TaxExempt *string `form:"tax_exempt"` - // The customer's tax IDs. - TaxIDs []*InvoiceUpcomingCustomerDetailsTaxIDParams `form:"tax_ids"` -} - -// Time span for the redeemed discount. -type InvoiceUpcomingDiscountDiscountEndDurationParams struct { - // Specifies a type of interval unit. Either `day`, `week`, `month` or `year`. - Interval *string `form:"interval"` - // The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration. - IntervalCount *int64 `form:"interval_count"` -} - -// The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details. -type InvoiceUpcomingInvoiceItemPeriodParams struct { - // The end of the period, which must be greater than or equal to the start. This value is inclusive. - End *int64 `form:"end"` - // The start of the period. This value is inclusive. - Start *int64 `form:"start"` -} - -// List of invoice items to add or update in the upcoming invoice preview. -type InvoiceUpcomingInvoiceItemParams struct { - // The integer amount in cents (or local equivalent) of previewed invoice item. - Amount *int64 `form:"amount"` - // Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Only applicable to new invoice items. - Currency *string `form:"currency"` - // An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking. - Description *string `form:"description"` - // Explicitly controls whether discounts apply to this invoice item. Defaults to true, except for negative invoice items. - Discountable *bool `form:"discountable"` - // The coupons to redeem into discounts for the invoice item in the preview. - Discounts []*InvoiceItemDiscountParams `form:"discounts"` - // The ID of the invoice item to update in preview. If not specified, a new invoice item will be added to the preview of the upcoming invoice. - InvoiceItem *string `form:"invoiceitem"` - // Set of [key-value pairs](https://stripe.com/docs/api/metadata) 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`. - Metadata map[string]string `form:"metadata"` - // The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details. - Period *InvoiceUpcomingInvoiceItemPeriodParams `form:"period"` - // The ID of the price object. - Price *string `form:"price"` - // Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. - PriceData *InvoiceItemPriceDataParams `form:"price_data"` - // Non-negative integer. The quantity of units for the invoice item. - Quantity *int64 `form:"quantity"` - // Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. - TaxBehavior *string `form:"tax_behavior"` - // A [tax code](https://stripe.com/docs/tax/tax-categories) ID. - TaxCode *string `form:"tax_code"` - // The tax rates that apply to the item. When set, any `default_tax_rates` do not apply to this item. - TaxRates []*string `form:"tax_rates"` - // The integer unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This unit_amount will be multiplied by the quantity to get the full amount. If you want to apply a credit to the customer's account, pass a negative unit_amount. - UnitAmount *int64 `form:"unit_amount"` - // Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set. - UnitAmountDecimal *float64 `form:"unit_amount_decimal,high_precision"` -} - -// The pre-billing to apply to the subscription as a preview. -type InvoiceUpcomingSubscriptionPrebillingParams struct { - // This is used to determine the number of billing cycles to prebill. - Iterations *int64 `form:"iterations"` -} - -// At any time, you can preview the upcoming invoice for a customer. This will show you all the charges that are pending, including subscription renewal charges, invoice item charges, etc. It will also show you any discounts that are applicable to the invoice. -// -// Note that when you are viewing an upcoming invoice, you are simply viewing a preview – the invoice has not yet been created. As such, the upcoming invoice will not show up in invoice listing calls, and you cannot use the API to pay or edit the invoice. If you want to change the amount that your customer will be billed, you can add, remove, or update pending invoice items, or update the customer's discount. -// -// You can preview the effects of updating a subscription, including a preview of what proration will take place. To ensure that the actual proration is calculated exactly the same as the previewed proration, you should pass a proration_date parameter when doing the actual subscription update. The value passed in should be the same as the subscription_proration_date returned on the upcoming invoice resource. The recommended way to get only the prorations being previewed is to consider only proration line items where period[start] is equal to the subscription_proration_date on the upcoming invoice resource. -type InvoiceUpcomingParams struct { - Params `form:"*"` - // Settings for automatic tax lookup for this invoice preview. - AutomaticTax *InvoiceAutomaticTaxParams `form:"automatic_tax"` - // The code of the coupon to apply. If `subscription` or `subscription_items` is provided, the invoice returned will preview updating or creating a subscription with that coupon. Otherwise, it will preview applying that coupon to the customer for the next upcoming invoice from among the customer's subscriptions. The invoice can be previewed without a coupon by passing this value as an empty string. - Coupon *string `form:"coupon"` - // The currency to preview this invoice in. Defaults to that of `customer` if not specified. - Currency *string `form:"currency"` - // The identifier of the customer whose upcoming invoice you'd like to retrieve. - Customer *string `form:"customer"` - // Details about the customer you want to invoice or overrides for an existing customer. - CustomerDetails *InvoiceUpcomingCustomerDetailsParams `form:"customer_details"` - // The coupons to redeem into discounts for the invoice preview. If not specified, inherits the discount from the customer or subscription. This only works for coupons directly applied to the invoice. To apply a coupon to a subscription, you must use the `coupon` parameter instead. Pass an empty string to avoid inheriting any discounts. To preview the upcoming invoice for a subscription that hasn't been created, use `coupon` instead. - Discounts []*InvoiceDiscountParams `form:"discounts"` - // List of invoice items to add or update in the upcoming invoice preview. - InvoiceItems []*InvoiceUpcomingInvoiceItemParams `form:"invoice_items"` - // The identifier of the unstarted schedule whose upcoming invoice you'd like to retrieve. Cannot be used with subscription or subscription fields. - Schedule *string `form:"schedule"` - // The identifier of the subscription for which you'd like to retrieve the upcoming invoice. If not provided, but a `subscription_items` is provided, you will preview creating a subscription with those items. If neither `subscription` nor `subscription_items` is provided, you will retrieve the next upcoming invoice from among the customer's subscriptions. - Subscription *string `form:"subscription"` - // For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`. - SubscriptionBillingCycleAnchor *int64 `form:"subscription_billing_cycle_anchor"` - SubscriptionBillingCycleAnchorNow *bool `form:"-"` // See custom AppendTo - SubscriptionBillingCycleAnchorUnchanged *bool `form:"-"` // See custom AppendTo - // Timestamp indicating when the subscription should be scheduled to cancel. Will prorate if within the current period and prorations have been enabled using `proration_behavior`. - SubscriptionCancelAt *int64 `form:"subscription_cancel_at"` - // Boolean indicating whether this subscription should cancel at the end of the current period. - SubscriptionCancelAtPeriodEnd *bool `form:"subscription_cancel_at_period_end"` - // This simulates the subscription being canceled or expired immediately. - SubscriptionCancelNow *bool `form:"subscription_cancel_now"` - // If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set. - SubscriptionDefaultTaxRates []*string `form:"subscription_default_tax_rates"` - // A list of up to 20 subscription items, each with an attached price. - SubscriptionItems []*SubscriptionItemsParams `form:"subscription_items"` - // The pre-billing to apply to the subscription as a preview. - SubscriptionPrebilling *InvoiceUpcomingSubscriptionPrebillingParams `form:"subscription_prebilling"` - // Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`. - SubscriptionProrationBehavior *string `form:"subscription_proration_behavior"` - // If previewing an update to a subscription, and doing proration, `subscription_proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period and within the current phase of the schedule backing this subscription, if the schedule exists. If set, `subscription`, and one of `subscription_items`, or `subscription_trial_end` are required. Also, `subscription_proration_behavior` cannot be set to 'none'. - SubscriptionProrationDate *int64 `form:"subscription_proration_date"` - // For paused subscriptions, setting `subscription_resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed. - SubscriptionResumeAt *string `form:"subscription_resume_at"` - // Date a subscription is intended to start (can be future or past) - SubscriptionStartDate *int64 `form:"subscription_start_date"` - // If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_items` or `subscription` is required. - SubscriptionTrialEnd *int64 `form:"subscription_trial_end"` - SubscriptionTrialEndNow *bool `form:"-"` // See custom AppendTo - // Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `subscription_trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `subscription_trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more. - SubscriptionTrialFromPlan *bool `form:"subscription_trial_from_plan"` -} - -// AppendTo implements custom encoding logic for InvoiceUpcomingParams. -func (i *InvoiceUpcomingParams) AppendTo(body *form.Values, keyParts []string) { - if BoolValue(i.SubscriptionBillingCycleAnchorNow) { - body.Add(form.FormatKey(append(keyParts, "subscription_billing_cycle_anchor")), "now") - } - if BoolValue(i.SubscriptionBillingCycleAnchorUnchanged) { - body.Add(form.FormatKey(append(keyParts, "subscription_billing_cycle_anchor")), "unchanged") - } - if BoolValue(i.SubscriptionTrialEndNow) { - body.Add(form.FormatKey(append(keyParts, "subscription_trial_end")), "now") - } -} // Stripe automatically creates and then attempts to collect payment on invoices for customers on subscriptions according to your [subscriptions settings](https://dashboard.stripe.com/account/billing/automatic). However, if you'd like to attempt payment on an invoice out of the normal collection schedule or for some other reason, you can do so. type InvoicePayParams struct { @@ -1067,6 +1057,31 @@ func (i *InvoiceUpcomingLinesParams) AppendTo(body *form.Values, keyParts []stri } } +// Revise an existing invoice. The new invoice will be created in `status=draft`. See the [revision documentation](https://stripe.com/docs/invoicing/invoice-revisions) for more details. +type InvoiceFromInvoiceParams struct { + // The relation between the new invoice and the original invoice. Currently, only 'revision' is permitted + Action *string `form:"action"` + // The `id` of the invoice that will be cloned. + Invoice *string `form:"invoice"` +} + +// You can list all invoices, or list the invoices for a specific customer. The invoices are returned sorted by creation date, with the most recently created invoices appearing first. +type InvoiceListParams struct { + ListParams `form:"*"` + // The collection method of the invoice to retrieve. Either `charge_automatically` or `send_invoice`. + CollectionMethod *string `form:"collection_method"` + Created *int64 `form:"created"` + CreatedRange *RangeQueryParams `form:"created"` + // Only return invoices for the customer specified by this customer ID. + Customer *string `form:"customer"` + DueDate *int64 `form:"due_date"` + DueDateRange *RangeQueryParams `form:"due_date"` + // The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview) + Status *string `form:"status"` + // Only return invoices for the subscription specified by this subscription ID. + Subscription *string `form:"subscription"` +} + // Stripe will automatically send invoices to customers according to your [subscriptions settings](https://dashboard.stripe.com/account/billing/automatic). However, if you'd like to manually send an invoice to your customer out of the normal schedule, you can do so. When sending invoices that have already been paid, there will be no reference to the payment in the email. // // Requests made in test-mode result in no emails being sent, despite sending an invoice.sent event. @@ -1161,7 +1176,7 @@ type InvoicePaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEUBank } type InvoicePaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer struct { EUBankTransfer *InvoicePaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEUBankTransfer `json:"eu_bank_transfer"` - // The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. + // The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`. Type string `json:"type"` } @@ -1256,6 +1271,20 @@ type InvoiceStatusTransitions struct { VoidedAt int64 `json:"voided_at"` } +// If specified, payment collection for this subscription will be paused. +type InvoiceSubscriptionDetailsPauseCollection struct { + // The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. + Behavior InvoiceSubscriptionDetailsPauseCollectionBehavior `json:"behavior"` + // The time after which the subscription will resume collecting payments. + ResumesAt int64 `json:"resumes_at"` +} + +// Details about the subscription that created this invoice. +type InvoiceSubscriptionDetails struct { + // If specified, payment collection for this subscription will be paused. + PauseCollection *InvoiceSubscriptionDetailsPauseCollection `json:"pause_collection"` +} + // Indicates which line items triggered a threshold invoice. type InvoiceThresholdReasonItemReason struct { // The IDs of the line items that triggered the threshold invoice. @@ -1467,6 +1496,8 @@ type Invoice struct { StatusTransitions *InvoiceStatusTransitions `json:"status_transitions"` // The subscription that this invoice was prepared for, if any. Subscription *Subscription `json:"subscription"` + // Details about the subscription that created this invoice. + SubscriptionDetails *InvoiceSubscriptionDetails `json:"subscription_details"` // Only set for upcoming invoices that preview prorations. The time used to calculate prorations. SubscriptionProrationDate int64 `json:"subscription_proration_date"` // Total of all subscriptions, invoice items, and prorations on the invoice before any invoice level discount or exclusive tax is applied. Item discounts are already incorporated diff --git a/issuing_cardholder.go b/issuing_cardholder.go index 8a637bfebd..e929c82101 100644 --- a/issuing_cardholder.go +++ b/issuing_cardholder.go @@ -8,6 +8,20 @@ package stripe import "encoding/json" +// The cardholder's preferred locales (languages), ordered by preference. Locales can be `de`, `en`, `es`, `fr`, or `it`. +// +// This changes the language of the [3D Secure flow](https://stripe.com/docs/issuing/3d-secure) and one-time password messages sent to the cardholder. +type IssuingCardholderPreferredLocale string + +// List of values that IssuingCardholderPreferredLocale can take +const ( + IssuingCardholderPreferredLocaleDE IssuingCardholderPreferredLocale = "de" + IssuingCardholderPreferredLocaleEN IssuingCardholderPreferredLocale = "en" + IssuingCardholderPreferredLocaleES IssuingCardholderPreferredLocale = "es" + IssuingCardholderPreferredLocaleFR IssuingCardholderPreferredLocale = "fr" + IssuingCardholderPreferredLocaleIT IssuingCardholderPreferredLocale = "it" +) + // If `disabled_reason` is present, all cards will decline authorizations with `cardholder_verification_required` reason. type IssuingCardholderRequirementsDisabledReason string @@ -172,6 +186,9 @@ type IssuingCardholderParams struct { // The cardholder's phone number. This is required for all cardholders who will be creating EU cards. // While phone number is optional if the cardholder will not be creating EU cards, note that this cardholder will not be eligible for 3DS without a phone number. See the [3D Secure documentation](https://stripe.com/docs/issuing/3d-secure#when-is-3d-secure-applied) for more details. PhoneNumber *string `form:"phone_number"` + // The cardholder's preferred locales (languages), ordered by preference. Locales can be `de`, `en`, `es`, `fr`, or `it`. + // This changes the language of the [3D Secure flow](https://stripe.com/docs/issuing/3d-secure) and one-time password messages sent to the cardholder. + PreferredLocales []*string `form:"preferred_locales"` // Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details. SpendingControls *IssuingCardholderSpendingControlsParams `form:"spending_controls"` // Specifies whether to permit authorizations on this cardholder's cards. @@ -296,8 +313,11 @@ type IssuingCardholder struct { // String representing the object's type. Objects of the same type share the same value. Object string `json:"object"` // The cardholder's phone number. This is required for all cardholders who will be creating EU cards. See the [3D Secure documentation](https://stripe.com/docs/issuing/3d-secure#when-is-3d-secure-applied) for more details. - PhoneNumber string `json:"phone_number"` - Requirements *IssuingCardholderRequirements `json:"requirements"` + PhoneNumber string `json:"phone_number"` + // The cardholder's preferred locales (languages), ordered by preference. Locales can be `de`, `en`, `es`, `fr`, or `it`. + // This changes the language of the [3D Secure flow](https://stripe.com/docs/issuing/3d-secure) and one-time password messages sent to the cardholder. + PreferredLocales []IssuingCardholderPreferredLocale `json:"preferred_locales"` + Requirements *IssuingCardholderRequirements `json:"requirements"` // Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details. SpendingControls *IssuingCardholderSpendingControls `json:"spending_controls"` // Specifies whether to permit authorizations on this cardholder's cards. diff --git a/order.go b/order.go index 5a8fc8140b..5508c3803f 100644 --- a/order.go +++ b/order.go @@ -109,10 +109,10 @@ type OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguage string // List of values that OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguage can take const ( - OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguageDe OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguage = "de" - OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguageEn OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguage = "en" - OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguageFr OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguage = "fr" - OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguageNl OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguage = "nl" + OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguageDE OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguage = "de" + OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguageEN OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguage = "en" + OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguageFR OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguage = "fr" + OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguageNL OrderPaymentSettingsPaymentMethodOptionsBancontactPreferredLanguage = "nl" ) // Indicates that you intend to make future payments with this PaymentIntent's payment method. @@ -174,14 +174,16 @@ type OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequeste // List of values that OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType can take const ( + OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeAba OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "aba" OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeIBAN OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "iban" OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeSEPA OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "sepa" OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeSortCode OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "sort_code" OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeSpei OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "spei" + OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeSwift OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "swift" OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeZengin OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "zengin" ) -// The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. +// The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`. type OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferType string // List of values that OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferType can take @@ -190,6 +192,7 @@ const ( OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferTypeGBBankTransfer OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferType = "gb_bank_transfer" OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferTypeJPBankTransfer OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferType = "jp_bank_transfer" OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferTypeMXBankTransfer OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferType = "mx_bank_transfer" + OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferTypeUSBankTransfer OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferType = "us_bank_transfer" ) // The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`. @@ -330,13 +333,13 @@ type OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage string // List of values that OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage can take const ( - OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguageDe OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage = "de" - OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguageEn OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage = "en" - OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguageEs OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage = "es" - OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguageFr OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage = "fr" - OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguageIt OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage = "it" - OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguageNl OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage = "nl" - OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguagePl OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage = "pl" + OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguageDE OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage = "de" + OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguageEN OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage = "en" + OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguageES OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage = "es" + OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguageFR OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage = "fr" + OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguageIT OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage = "it" + OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguageNL OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage = "nl" + OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguagePL OrderPaymentSettingsPaymentMethodOptionsSofortPreferredLanguage = "pl" ) // Indicates that you intend to make future payments with this PaymentIntent's payment method. @@ -791,7 +794,7 @@ type OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferParams s // // Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`. RequestedAddressTypes []*string `form:"requested_address_types"` - // The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. + // The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`. Type *string `form:"type"` } @@ -1297,7 +1300,7 @@ type OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer struct // // Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`. RequestedAddressTypes []OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType `json:"requested_address_types"` - // The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. + // The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`. Type OrderPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferType `json:"type"` } type OrderPaymentSettingsPaymentMethodOptionsCustomerBalance struct { diff --git a/paymentintent.go b/paymentintent.go index f5cf27fdfd..8a266e418d 100644 --- a/paymentintent.go +++ b/paymentintent.go @@ -72,6 +72,7 @@ const ( PaymentIntentNextActionDisplayBankTransferInstructionsTypeGBBankTransfer PaymentIntentNextActionDisplayBankTransferInstructionsType = "gb_bank_transfer" PaymentIntentNextActionDisplayBankTransferInstructionsTypeJPBankTransfer PaymentIntentNextActionDisplayBankTransferInstructionsType = "jp_bank_transfer" PaymentIntentNextActionDisplayBankTransferInstructionsTypeMXBankTransfer PaymentIntentNextActionDisplayBankTransferInstructionsType = "mx_bank_transfer" + PaymentIntentNextActionDisplayBankTransferInstructionsTypeUSBankTransfer PaymentIntentNextActionDisplayBankTransferInstructionsType = "us_bank_transfer" ) // Type of the next action to perform, one of `redirect_to_url`, `use_stripe_sdk`, `alipay_handle_redirect`, `oxxo_display_details`, or `verify_with_microdeposits`. @@ -371,14 +372,16 @@ type PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddres // List of values that PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType can take const ( + PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeAba PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "aba" PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeIBAN PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "iban" PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeSEPA PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "sepa" PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeSortCode PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "sort_code" PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeSpei PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "spei" + PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeSwift PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "swift" PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressTypeZengin PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType = "zengin" ) -// The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. +// The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`. type PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferType string // List of values that PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferType can take @@ -387,6 +390,7 @@ const ( PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferTypeGBBankTransfer PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferType = "gb_bank_transfer" PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferTypeJPBankTransfer PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferType = "jp_bank_transfer" PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferTypeMXBankTransfer PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferType = "mx_bank_transfer" + PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferTypeUSBankTransfer PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferType = "us_bank_transfer" ) // The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`. @@ -1216,7 +1220,7 @@ type PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferParams struct { // // Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`. RequestedAddressTypes []*string `form:"requested_address_types"` - // The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. + // The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`. Type *string `form:"type"` } @@ -2388,7 +2392,7 @@ type PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransfer struct { // // Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`. RequestedAddressTypes []PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferRequestedAddressType `json:"requested_address_types"` - // The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. + // The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`. Type PaymentIntentPaymentMethodOptionsCustomerBalanceBankTransferType `json:"type"` } type PaymentIntentPaymentMethodOptionsCustomerBalance struct { diff --git a/paymentmethod.go b/paymentmethod.go index 9d0577a641..f564bce9a5 100644 --- a/paymentmethod.go +++ b/paymentmethod.go @@ -698,6 +698,8 @@ type PaymentMethodCardPresent struct { CardholderName string `json:"cardholder_name"` // Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected. Country string `json:"country"` + // A high-level description of the type of cards issued in this range. (For internal use only and not typically available in standard API requests.) + Description string `json:"description"` // Two-digit number representing the card's expiration month. ExpMonth int64 `json:"exp_month"` // Four-digit number representing the card's expiration year. @@ -708,6 +710,10 @@ type PaymentMethodCardPresent struct { Fingerprint string `json:"fingerprint"` // Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`. Funding string `json:"funding"` + // Issuer identification number of the card. (For internal use only and not typically available in standard API requests.) + IIN string `json:"iin"` + // The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.) + Issuer string `json:"issuer"` // The last four digits of the card. Last4 string `json:"last4"` // Contains information about card networks that can be used to process the payment. @@ -755,6 +761,8 @@ type PaymentMethodInteracPresent struct { CardholderName string `json:"cardholder_name"` // Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected. Country string `json:"country"` + // A high-level description of the type of cards issued in this range. (For internal use only and not typically available in standard API requests.) + Description string `json:"description"` // Two-digit number representing the card's expiration month. ExpMonth int64 `json:"exp_month"` // Four-digit number representing the card's expiration year. @@ -765,6 +773,10 @@ type PaymentMethodInteracPresent struct { Fingerprint string `json:"fingerprint"` // Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`. Funding string `json:"funding"` + // Issuer identification number of the card. (For internal use only and not typically available in standard API requests.) + IIN string `json:"iin"` + // The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.) + Issuer string `json:"issuer"` // The last four digits of the card. Last4 string `json:"last4"` // Contains information about card networks that can be used to process the payment. @@ -807,6 +819,9 @@ type PaymentMethodPayNow struct{} type PaymentMethodPaypal struct { // Uniquely identifies this particular PayPal account. You can use this attribute to check whether two PayPal accounts are the same. Fingerprint string `json:"fingerprint"` + // Owner's email. Values are provided by PayPal directly + // (if supported) at the time of authorization or settlement. They cannot be set or mutated. + PayerEmail string `json:"payer_email"` // PayPal account PayerID. This identifier uniquely identifies the PayPal customer. PayerID string `json:"payer_id"` // Owner's verified email. Values are verified or provided by PayPal directly diff --git a/quote.go b/quote.go index 34d64e8e58..365f5d9eca 100644 --- a/quote.go +++ b/quote.go @@ -137,10 +137,11 @@ type QuoteSubscriptionDataBillOnAcceptanceBillFromType string // List of values that QuoteSubscriptionDataBillOnAcceptanceBillFromType can take const ( - QuoteSubscriptionDataBillOnAcceptanceBillFromTypeLineStartsAt QuoteSubscriptionDataBillOnAcceptanceBillFromType = "line_starts_at" - QuoteSubscriptionDataBillOnAcceptanceBillFromTypeNow QuoteSubscriptionDataBillOnAcceptanceBillFromType = "now" - QuoteSubscriptionDataBillOnAcceptanceBillFromTypeQuoteAcceptanceDate QuoteSubscriptionDataBillOnAcceptanceBillFromType = "quote_acceptance_date" - QuoteSubscriptionDataBillOnAcceptanceBillFromTypeTimestamp QuoteSubscriptionDataBillOnAcceptanceBillFromType = "timestamp" + QuoteSubscriptionDataBillOnAcceptanceBillFromTypeLineStartsAt QuoteSubscriptionDataBillOnAcceptanceBillFromType = "line_starts_at" + QuoteSubscriptionDataBillOnAcceptanceBillFromTypeNow QuoteSubscriptionDataBillOnAcceptanceBillFromType = "now" + QuoteSubscriptionDataBillOnAcceptanceBillFromTypePauseCollectionStart QuoteSubscriptionDataBillOnAcceptanceBillFromType = "pause_collection_start" + QuoteSubscriptionDataBillOnAcceptanceBillFromTypeQuoteAcceptanceDate QuoteSubscriptionDataBillOnAcceptanceBillFromType = "quote_acceptance_date" + QuoteSubscriptionDataBillOnAcceptanceBillFromTypeTimestamp QuoteSubscriptionDataBillOnAcceptanceBillFromType = "timestamp" ) // Specifies a type of interval unit. Either `day`, `week`, `month` or `year`. @@ -216,10 +217,11 @@ type QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromType string // List of values that QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromType can take const ( - QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromTypeLineStartsAt QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromType = "line_starts_at" - QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromTypeNow QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromType = "now" - QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromTypeQuoteAcceptanceDate QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromType = "quote_acceptance_date" - QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromTypeTimestamp QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromType = "timestamp" + QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromTypeLineStartsAt QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromType = "line_starts_at" + QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromTypeNow QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromType = "now" + QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromTypePauseCollectionStart QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromType = "pause_collection_start" + QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromTypeQuoteAcceptanceDate QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromType = "quote_acceptance_date" + QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromTypeTimestamp QuoteSubscriptionDataOverrideBillOnAcceptanceBillFromType = "timestamp" ) // Specifies a type of interval unit. Either `day`, `week`, `month` or `year`. @@ -666,6 +668,20 @@ type QuoteLineEndsAtParams struct { Type *string `form:"type"` } +// Details of the pause_collection behavior to apply to the amendment. +type QuoteLineSetPauseCollectionSetParams struct { + // The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. + Behavior *string `form:"behavior"` +} + +// Defines how to pause collection for the underlying subscription throughout the duration of the amendment. +type QuoteLineSetPauseCollectionParams struct { + // Details of the pause_collection behavior to apply to the amendment. + Set *QuoteLineSetPauseCollectionSetParams `form:"set"` + // Determines the type of the pause_collection amendment. + Type *string `form:"type"` +} + // Use the `end` time of a given discount. type QuoteLineStartsAtDiscountEndParams struct { // The ID of a specific discount. @@ -718,6 +734,8 @@ type QuoteLineParams struct { ID *string `form:"id"` // Changes to how Stripe handles prorations during the quote line's time span. Affects if and how prorations are created when a future phase starts. ProrationBehavior *string `form:"proration_behavior"` + // Defines how to pause collection for the underlying subscription throughout the duration of the amendment. + SetPauseCollection *QuoteLineSetPauseCollectionParams `form:"set_pause_collection"` // Timestamp helper to end the underlying schedule early, based on the acompanying line's start or end date. SetScheduleEnd *string `form:"set_schedule_end"` // Details to identify the earliest timestamp where the proposed change should take effect. diff --git a/quoteline.go b/quoteline.go index f3fb78fe02..e3ed788140 100644 --- a/quoteline.go +++ b/quoteline.go @@ -132,6 +132,25 @@ const ( QuoteLineProrationBehaviorNone QuoteLineProrationBehavior = "none" ) +// The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. +type QuoteLineSetPauseCollectionSetBehavior string + +// List of values that QuoteLineSetPauseCollectionSetBehavior can take +const ( + QuoteLineSetPauseCollectionSetBehaviorKeepAsDraft QuoteLineSetPauseCollectionSetBehavior = "keep_as_draft" + QuoteLineSetPauseCollectionSetBehaviorMarkUncollectible QuoteLineSetPauseCollectionSetBehavior = "mark_uncollectible" + QuoteLineSetPauseCollectionSetBehaviorVoid QuoteLineSetPauseCollectionSetBehavior = "void" +) + +// Defines the type of the pause_collection behavior for the quote line. +type QuoteLineSetPauseCollectionType string + +// List of values that QuoteLineSetPauseCollectionType can take +const ( + QuoteLineSetPauseCollectionTypeRemove QuoteLineSetPauseCollectionType = "remove" + QuoteLineSetPauseCollectionTypeSet QuoteLineSetPauseCollectionType = "set" +) + // Timestamp helper to end the underlying schedule early, based on the acompanying line's start or end date. type QuoteLineSetScheduleEnd string @@ -368,6 +387,20 @@ type QuoteLineEndsAt struct { Type QuoteLineEndsAtType `json:"type"` } +// If specified, payment collection for this subscription will be paused. +type QuoteLineSetPauseCollectionSet struct { + // The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. + Behavior QuoteLineSetPauseCollectionSetBehavior `json:"behavior"` +} + +// Details to modify the pause_collection behavior of the subscription schedule. +type QuoteLineSetPauseCollection struct { + // If specified, payment collection for this subscription will be paused. + Set *QuoteLineSetPauseCollectionSet `json:"set"` + // Defines the type of the pause_collection behavior for the quote line. + Type QuoteLineSetPauseCollectionType `json:"type"` +} + // Use the `end` time of a given discount. type QuoteLineStartsAtDiscountEnd struct { // The ID of a specific discount. @@ -422,6 +455,8 @@ type QuoteLine struct { Object string `json:"object"` // Changes to how Stripe handles prorations during the quote line's time span. Affects if and how prorations are created when a future phase starts. ProrationBehavior QuoteLineProrationBehavior `json:"proration_behavior"` + // Details to modify the pause_collection behavior of the subscription schedule. + SetPauseCollection *QuoteLineSetPauseCollection `json:"set_pause_collection"` // Timestamp helper to end the underlying schedule early, based on the acompanying line's start or end date. SetScheduleEnd QuoteLineSetScheduleEnd `json:"set_schedule_end"` // Details to identify the earliest timestamp where the proposed change should take effect. diff --git a/subscription.go b/subscription.go index 8c09ef5d69..468bdf1012 100644 --- a/subscription.go +++ b/subscription.go @@ -439,7 +439,7 @@ type SubscriptionPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferE type SubscriptionPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferParams struct { // Configuration for eu_bank_transfer funding type. EUBankTransfer *SubscriptionPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEUBankTransferParams `form:"eu_bank_transfer"` - // The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. + // The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`. Type *string `form:"type"` } @@ -759,7 +759,7 @@ type SubscriptionPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferE } type SubscriptionPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransfer struct { EUBankTransfer *SubscriptionPaymentSettingsPaymentMethodOptionsCustomerBalanceBankTransferEUBankTransfer `json:"eu_bank_transfer"` - // The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. + // The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`. Type string `json:"type"` } diff --git a/subscriptionschedule.go b/subscriptionschedule.go index 17df60ebb8..adec381827 100644 --- a/subscriptionschedule.go +++ b/subscriptionschedule.go @@ -90,6 +90,16 @@ const ( SubscriptionSchedulePhaseItemTrialTypePaid SubscriptionSchedulePhaseItemTrialType = "paid" ) +// The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. +type SubscriptionSchedulePhasePauseCollectionBehavior string + +// List of values that SubscriptionSchedulePhasePauseCollectionBehavior can take +const ( + SubscriptionSchedulePhasePauseCollectionBehaviorKeepAsDraft SubscriptionSchedulePhasePauseCollectionBehavior = "keep_as_draft" + SubscriptionSchedulePhasePauseCollectionBehaviorMarkUncollectible SubscriptionSchedulePhasePauseCollectionBehavior = "mark_uncollectible" + SubscriptionSchedulePhasePauseCollectionBehaviorVoid SubscriptionSchedulePhasePauseCollectionBehavior = "void" +) + // If the subscription schedule will prorate when transitioning to this phase. Possible values are `create_prorations` and `none`. type SubscriptionSchedulePhaseProrationBehavior string @@ -335,6 +345,12 @@ type SubscriptionSchedulePhaseItemParams struct { Trial *SubscriptionSchedulePhaseItemTrialParams `form:"trial"` } +// If specified, payment collection for this subscription will be paused. +type SubscriptionSchedulePhasePauseCollectionParams struct { + // The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. + Behavior *string `form:"behavior"` +} + // Defines how the subscription should behave when a trial ends. type SubscriptionSchedulePhaseTrialSettingsEndBehaviorParams struct { // Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`. @@ -386,6 +402,8 @@ type SubscriptionSchedulePhaseParams struct { Metadata map[string]string `form:"metadata"` // The account on behalf of which to charge, for each of the associated subscription's invoices. OnBehalfOf *string `form:"on_behalf_of"` + // If specified, payment collection for this subscription will be paused. + PauseCollection *SubscriptionSchedulePhasePauseCollectionParams `form:"pause_collection"` // Whether the subscription schedule will create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase. The default value is `create_prorations`. This setting controls prorations when a phase is started asynchronously and it is persisted as a field on the phase. It's different from the request-level [proration_behavior](https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration of the current phase. ProrationBehavior *string `form:"proration_behavior"` // The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase. @@ -686,6 +704,20 @@ type SubscriptionScheduleAmendAmendmentMetadataActionParams struct { Type *string `form:"type"` } +// Details of the pause_collection behavior to apply to the amendment. +type SubscriptionScheduleAmendAmendmentSetPauseCollectionSetParams struct { + // The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. + Behavior *string `form:"behavior"` +} + +// Defines how to pause collection for the underlying subscription throughout the duration of the amendment. +type SubscriptionScheduleAmendAmendmentSetPauseCollectionParams struct { + // Details of the pause_collection behavior to apply to the amendment. + Set *SubscriptionScheduleAmendAmendmentSetPauseCollectionSetParams `form:"set"` + // Determines the type of the pause_collection amendment. + Type *string `form:"type"` +} + // Defines how the subscription should behave when a trial ends. type SubscriptionScheduleAmendAmendmentTrialSettingsEndBehaviorParams struct { // Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`. @@ -714,6 +746,8 @@ type SubscriptionScheduleAmendAmendmentParams struct { MetadataActions []*SubscriptionScheduleAmendAmendmentMetadataActionParams `form:"metadata_actions"` // Changes to how Stripe handles prorations during the amendment time span. Affects if and how prorations are created when a future phase starts. In cases where the amendment changes the currently active phase, it is used to determine whether or how to prorate now, at the time of the request. Also supported as a point-in-time operation when `amendment_end` is `null`. ProrationBehavior *string `form:"proration_behavior"` + // Defines how to pause collection for the underlying subscription throughout the duration of the amendment. + SetPauseCollection *SubscriptionScheduleAmendAmendmentSetPauseCollectionParams `form:"set_pause_collection"` // Ends the subscription schedule early as dictated by either the accompanying amendment's start or end. SetScheduleEnd *string `form:"set_schedule_end"` // Settings related to subscription trials. @@ -952,6 +986,12 @@ type SubscriptionSchedulePhaseItem struct { Trial *SubscriptionSchedulePhaseItemTrial `json:"trial"` } +// If specified, payment collection for this subscription will be paused. +type SubscriptionSchedulePhasePauseCollection struct { + // The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. + Behavior SubscriptionSchedulePhasePauseCollectionBehavior `json:"behavior"` +} + // Defines how the subscription should behaves when a trial ensd. type SubscriptionSchedulePhaseTrialSettingsEndBehavior struct { // Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`. @@ -999,6 +1039,8 @@ type SubscriptionSchedulePhase struct { Metadata map[string]string `json:"metadata"` // The account (if any) the charge was made on behalf of for charges associated with the schedule's subscription. See the Connect documentation for details. OnBehalfOf *Account `json:"on_behalf_of"` + // If specified, payment collection for this subscription will be paused. + PauseCollection *SubscriptionSchedulePhasePauseCollection `json:"pause_collection"` // If the subscription schedule will prorate when transitioning to this phase. Possible values are `create_prorations` and `none`. ProrationBehavior SubscriptionSchedulePhaseProrationBehavior `json:"proration_behavior"` // The start of this phase of the subscription schedule. diff --git a/tax_registration.go b/tax_registration.go index 1d66d482a9..e8fdb8970c 100644 --- a/tax_registration.go +++ b/tax_registration.go @@ -65,23 +65,23 @@ const ( ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsBgStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsBGStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsBgStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsBGStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsBgStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsBgStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsBgStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsBgStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsBGStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsBGStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsBGStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsBGStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsBgType string +type TaxRegistrationCountryOptionsBGType string -// List of values that TaxRegistrationCountryOptionsBgType can take +// List of values that TaxRegistrationCountryOptionsBGType can take const ( - TaxRegistrationCountryOptionsBgTypeIoss TaxRegistrationCountryOptionsBgType = "ioss" - TaxRegistrationCountryOptionsBgTypeOssNonUnion TaxRegistrationCountryOptionsBgType = "oss_non_union" - TaxRegistrationCountryOptionsBgTypeOssUnion TaxRegistrationCountryOptionsBgType = "oss_union" - TaxRegistrationCountryOptionsBgTypeStandard TaxRegistrationCountryOptionsBgType = "standard" + TaxRegistrationCountryOptionsBGTypeIoss TaxRegistrationCountryOptionsBGType = "ioss" + TaxRegistrationCountryOptionsBGTypeOssNonUnion TaxRegistrationCountryOptionsBGType = "oss_non_union" + TaxRegistrationCountryOptionsBGTypeOssUnion TaxRegistrationCountryOptionsBGType = "oss_union" + TaxRegistrationCountryOptionsBGTypeStandard TaxRegistrationCountryOptionsBGType = "standard" ) // Type of registration in Canada. @@ -143,23 +143,23 @@ const ( ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsDeStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsDEStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsDeStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsDEStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsDeStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsDeStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsDeStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsDeStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsDEStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsDEStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsDEStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsDEStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsDeType string +type TaxRegistrationCountryOptionsDEType string -// List of values that TaxRegistrationCountryOptionsDeType can take +// List of values that TaxRegistrationCountryOptionsDEType can take const ( - TaxRegistrationCountryOptionsDeTypeIoss TaxRegistrationCountryOptionsDeType = "ioss" - TaxRegistrationCountryOptionsDeTypeOssNonUnion TaxRegistrationCountryOptionsDeType = "oss_non_union" - TaxRegistrationCountryOptionsDeTypeOssUnion TaxRegistrationCountryOptionsDeType = "oss_union" - TaxRegistrationCountryOptionsDeTypeStandard TaxRegistrationCountryOptionsDeType = "standard" + TaxRegistrationCountryOptionsDETypeIoss TaxRegistrationCountryOptionsDEType = "ioss" + TaxRegistrationCountryOptionsDETypeOssNonUnion TaxRegistrationCountryOptionsDEType = "oss_non_union" + TaxRegistrationCountryOptionsDETypeOssUnion TaxRegistrationCountryOptionsDEType = "oss_union" + TaxRegistrationCountryOptionsDETypeStandard TaxRegistrationCountryOptionsDEType = "standard" ) // Place of supply scheme used in an EU standard registration. @@ -203,63 +203,63 @@ const ( ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsEsStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsESStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsEsStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsESStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsEsStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsEsStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsEsStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsEsStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsESStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsESStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsESStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsESStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsEsType string +type TaxRegistrationCountryOptionsESType string -// List of values that TaxRegistrationCountryOptionsEsType can take +// List of values that TaxRegistrationCountryOptionsESType can take const ( - TaxRegistrationCountryOptionsEsTypeIoss TaxRegistrationCountryOptionsEsType = "ioss" - TaxRegistrationCountryOptionsEsTypeOssNonUnion TaxRegistrationCountryOptionsEsType = "oss_non_union" - TaxRegistrationCountryOptionsEsTypeOssUnion TaxRegistrationCountryOptionsEsType = "oss_union" - TaxRegistrationCountryOptionsEsTypeStandard TaxRegistrationCountryOptionsEsType = "standard" + TaxRegistrationCountryOptionsESTypeIoss TaxRegistrationCountryOptionsESType = "ioss" + TaxRegistrationCountryOptionsESTypeOssNonUnion TaxRegistrationCountryOptionsESType = "oss_non_union" + TaxRegistrationCountryOptionsESTypeOssUnion TaxRegistrationCountryOptionsESType = "oss_union" + TaxRegistrationCountryOptionsESTypeStandard TaxRegistrationCountryOptionsESType = "standard" ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsFiStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsFIStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsFiStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsFIStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsFiStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsFiStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsFiStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsFiStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsFIStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsFIStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsFIStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsFIStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsFiType string +type TaxRegistrationCountryOptionsFIType string -// List of values that TaxRegistrationCountryOptionsFiType can take +// List of values that TaxRegistrationCountryOptionsFIType can take const ( - TaxRegistrationCountryOptionsFiTypeIoss TaxRegistrationCountryOptionsFiType = "ioss" - TaxRegistrationCountryOptionsFiTypeOssNonUnion TaxRegistrationCountryOptionsFiType = "oss_non_union" - TaxRegistrationCountryOptionsFiTypeOssUnion TaxRegistrationCountryOptionsFiType = "oss_union" - TaxRegistrationCountryOptionsFiTypeStandard TaxRegistrationCountryOptionsFiType = "standard" + TaxRegistrationCountryOptionsFITypeIoss TaxRegistrationCountryOptionsFIType = "ioss" + TaxRegistrationCountryOptionsFITypeOssNonUnion TaxRegistrationCountryOptionsFIType = "oss_non_union" + TaxRegistrationCountryOptionsFITypeOssUnion TaxRegistrationCountryOptionsFIType = "oss_union" + TaxRegistrationCountryOptionsFITypeStandard TaxRegistrationCountryOptionsFIType = "standard" ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsFrStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsFRStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsFrStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsFRStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsFrStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsFrStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsFrStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsFrStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsFRStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsFRStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsFRStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsFRStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsFrType string +type TaxRegistrationCountryOptionsFRType string -// List of values that TaxRegistrationCountryOptionsFrType can take +// List of values that TaxRegistrationCountryOptionsFRType can take const ( - TaxRegistrationCountryOptionsFrTypeIoss TaxRegistrationCountryOptionsFrType = "ioss" - TaxRegistrationCountryOptionsFrTypeOssNonUnion TaxRegistrationCountryOptionsFrType = "oss_non_union" - TaxRegistrationCountryOptionsFrTypeOssUnion TaxRegistrationCountryOptionsFrType = "oss_union" - TaxRegistrationCountryOptionsFrTypeStandard TaxRegistrationCountryOptionsFrType = "standard" + TaxRegistrationCountryOptionsFRTypeIoss TaxRegistrationCountryOptionsFRType = "ioss" + TaxRegistrationCountryOptionsFRTypeOssNonUnion TaxRegistrationCountryOptionsFRType = "oss_non_union" + TaxRegistrationCountryOptionsFRTypeOssUnion TaxRegistrationCountryOptionsFRType = "oss_union" + TaxRegistrationCountryOptionsFRTypeStandard TaxRegistrationCountryOptionsFRType = "standard" ) // Type of registration in `country`. @@ -299,43 +299,43 @@ const ( ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsHrStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsHRStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsHrStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsHRStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsHrStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsHrStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsHrStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsHrStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsHRStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsHRStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsHRStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsHRStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsHrType string +type TaxRegistrationCountryOptionsHRType string -// List of values that TaxRegistrationCountryOptionsHrType can take +// List of values that TaxRegistrationCountryOptionsHRType can take const ( - TaxRegistrationCountryOptionsHrTypeIoss TaxRegistrationCountryOptionsHrType = "ioss" - TaxRegistrationCountryOptionsHrTypeOssNonUnion TaxRegistrationCountryOptionsHrType = "oss_non_union" - TaxRegistrationCountryOptionsHrTypeOssUnion TaxRegistrationCountryOptionsHrType = "oss_union" - TaxRegistrationCountryOptionsHrTypeStandard TaxRegistrationCountryOptionsHrType = "standard" + TaxRegistrationCountryOptionsHRTypeIoss TaxRegistrationCountryOptionsHRType = "ioss" + TaxRegistrationCountryOptionsHRTypeOssNonUnion TaxRegistrationCountryOptionsHRType = "oss_non_union" + TaxRegistrationCountryOptionsHRTypeOssUnion TaxRegistrationCountryOptionsHRType = "oss_union" + TaxRegistrationCountryOptionsHRTypeStandard TaxRegistrationCountryOptionsHRType = "standard" ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsHuStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsHUStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsHuStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsHUStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsHuStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsHuStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsHuStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsHuStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsHUStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsHUStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsHUStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsHUStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsHuType string +type TaxRegistrationCountryOptionsHUType string -// List of values that TaxRegistrationCountryOptionsHuType can take +// List of values that TaxRegistrationCountryOptionsHUType can take const ( - TaxRegistrationCountryOptionsHuTypeIoss TaxRegistrationCountryOptionsHuType = "ioss" - TaxRegistrationCountryOptionsHuTypeOssNonUnion TaxRegistrationCountryOptionsHuType = "oss_non_union" - TaxRegistrationCountryOptionsHuTypeOssUnion TaxRegistrationCountryOptionsHuType = "oss_union" - TaxRegistrationCountryOptionsHuTypeStandard TaxRegistrationCountryOptionsHuType = "standard" + TaxRegistrationCountryOptionsHUTypeIoss TaxRegistrationCountryOptionsHUType = "ioss" + TaxRegistrationCountryOptionsHUTypeOssNonUnion TaxRegistrationCountryOptionsHUType = "oss_non_union" + TaxRegistrationCountryOptionsHUTypeOssUnion TaxRegistrationCountryOptionsHUType = "oss_union" + TaxRegistrationCountryOptionsHUTypeStandard TaxRegistrationCountryOptionsHUType = "standard" ) // Place of supply scheme used in an EU standard registration. @@ -367,23 +367,23 @@ const ( ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsItStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsITStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsItStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsITStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsItStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsItStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsItStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsItStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsITStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsITStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsITStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsITStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsItType string +type TaxRegistrationCountryOptionsITType string -// List of values that TaxRegistrationCountryOptionsItType can take +// List of values that TaxRegistrationCountryOptionsITType can take const ( - TaxRegistrationCountryOptionsItTypeIoss TaxRegistrationCountryOptionsItType = "ioss" - TaxRegistrationCountryOptionsItTypeOssNonUnion TaxRegistrationCountryOptionsItType = "oss_non_union" - TaxRegistrationCountryOptionsItTypeOssUnion TaxRegistrationCountryOptionsItType = "oss_union" - TaxRegistrationCountryOptionsItTypeStandard TaxRegistrationCountryOptionsItType = "standard" + TaxRegistrationCountryOptionsITTypeIoss TaxRegistrationCountryOptionsITType = "ioss" + TaxRegistrationCountryOptionsITTypeOssNonUnion TaxRegistrationCountryOptionsITType = "oss_non_union" + TaxRegistrationCountryOptionsITTypeOssUnion TaxRegistrationCountryOptionsITType = "oss_union" + TaxRegistrationCountryOptionsITTypeStandard TaxRegistrationCountryOptionsITType = "standard" ) // Type of registration in `country`. @@ -395,23 +395,23 @@ const ( ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsLtStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsLTStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsLtStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsLTStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsLtStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsLtStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsLtStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsLtStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsLTStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsLTStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsLTStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsLTStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsLtType string +type TaxRegistrationCountryOptionsLTType string -// List of values that TaxRegistrationCountryOptionsLtType can take +// List of values that TaxRegistrationCountryOptionsLTType can take const ( - TaxRegistrationCountryOptionsLtTypeIoss TaxRegistrationCountryOptionsLtType = "ioss" - TaxRegistrationCountryOptionsLtTypeOssNonUnion TaxRegistrationCountryOptionsLtType = "oss_non_union" - TaxRegistrationCountryOptionsLtTypeOssUnion TaxRegistrationCountryOptionsLtType = "oss_union" - TaxRegistrationCountryOptionsLtTypeStandard TaxRegistrationCountryOptionsLtType = "standard" + TaxRegistrationCountryOptionsLTTypeIoss TaxRegistrationCountryOptionsLTType = "ioss" + TaxRegistrationCountryOptionsLTTypeOssNonUnion TaxRegistrationCountryOptionsLTType = "oss_non_union" + TaxRegistrationCountryOptionsLTTypeOssUnion TaxRegistrationCountryOptionsLTType = "oss_union" + TaxRegistrationCountryOptionsLTTypeStandard TaxRegistrationCountryOptionsLTType = "standard" ) // Place of supply scheme used in an EU standard registration. @@ -435,63 +435,63 @@ const ( ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsLvStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsLVStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsLvStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsLVStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsLvStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsLvStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsLvStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsLvStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsLVStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsLVStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsLVStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsLVStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsLvType string +type TaxRegistrationCountryOptionsLVType string -// List of values that TaxRegistrationCountryOptionsLvType can take +// List of values that TaxRegistrationCountryOptionsLVType can take const ( - TaxRegistrationCountryOptionsLvTypeIoss TaxRegistrationCountryOptionsLvType = "ioss" - TaxRegistrationCountryOptionsLvTypeOssNonUnion TaxRegistrationCountryOptionsLvType = "oss_non_union" - TaxRegistrationCountryOptionsLvTypeOssUnion TaxRegistrationCountryOptionsLvType = "oss_union" - TaxRegistrationCountryOptionsLvTypeStandard TaxRegistrationCountryOptionsLvType = "standard" + TaxRegistrationCountryOptionsLVTypeIoss TaxRegistrationCountryOptionsLVType = "ioss" + TaxRegistrationCountryOptionsLVTypeOssNonUnion TaxRegistrationCountryOptionsLVType = "oss_non_union" + TaxRegistrationCountryOptionsLVTypeOssUnion TaxRegistrationCountryOptionsLVType = "oss_union" + TaxRegistrationCountryOptionsLVTypeStandard TaxRegistrationCountryOptionsLVType = "standard" ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsMtStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsMTStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsMtStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsMTStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsMtStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsMtStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsMtStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsMtStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsMTStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsMTStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsMTStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsMTStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsMtType string +type TaxRegistrationCountryOptionsMTType string -// List of values that TaxRegistrationCountryOptionsMtType can take +// List of values that TaxRegistrationCountryOptionsMTType can take const ( - TaxRegistrationCountryOptionsMtTypeIoss TaxRegistrationCountryOptionsMtType = "ioss" - TaxRegistrationCountryOptionsMtTypeOssNonUnion TaxRegistrationCountryOptionsMtType = "oss_non_union" - TaxRegistrationCountryOptionsMtTypeOssUnion TaxRegistrationCountryOptionsMtType = "oss_union" - TaxRegistrationCountryOptionsMtTypeStandard TaxRegistrationCountryOptionsMtType = "standard" + TaxRegistrationCountryOptionsMTTypeIoss TaxRegistrationCountryOptionsMTType = "ioss" + TaxRegistrationCountryOptionsMTTypeOssNonUnion TaxRegistrationCountryOptionsMTType = "oss_non_union" + TaxRegistrationCountryOptionsMTTypeOssUnion TaxRegistrationCountryOptionsMTType = "oss_union" + TaxRegistrationCountryOptionsMTTypeStandard TaxRegistrationCountryOptionsMTType = "standard" ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsNlStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsNLStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsNlStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsNLStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsNlStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsNlStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsNlStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsNlStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsNLStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsNLStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsNLStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsNLStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsNlType string +type TaxRegistrationCountryOptionsNLType string -// List of values that TaxRegistrationCountryOptionsNlType can take +// List of values that TaxRegistrationCountryOptionsNLType can take const ( - TaxRegistrationCountryOptionsNlTypeIoss TaxRegistrationCountryOptionsNlType = "ioss" - TaxRegistrationCountryOptionsNlTypeOssNonUnion TaxRegistrationCountryOptionsNlType = "oss_non_union" - TaxRegistrationCountryOptionsNlTypeOssUnion TaxRegistrationCountryOptionsNlType = "oss_union" - TaxRegistrationCountryOptionsNlTypeStandard TaxRegistrationCountryOptionsNlType = "standard" + TaxRegistrationCountryOptionsNLTypeIoss TaxRegistrationCountryOptionsNLType = "ioss" + TaxRegistrationCountryOptionsNLTypeOssNonUnion TaxRegistrationCountryOptionsNLType = "oss_non_union" + TaxRegistrationCountryOptionsNLTypeOssUnion TaxRegistrationCountryOptionsNLType = "oss_union" + TaxRegistrationCountryOptionsNLTypeStandard TaxRegistrationCountryOptionsNLType = "standard" ) // Type of registration in `country`. @@ -511,63 +511,63 @@ const ( ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsPlStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsPLStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsPlStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsPLStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsPlStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsPlStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsPlStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsPlStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsPLStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsPLStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsPLStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsPLStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsPlType string +type TaxRegistrationCountryOptionsPLType string -// List of values that TaxRegistrationCountryOptionsPlType can take +// List of values that TaxRegistrationCountryOptionsPLType can take const ( - TaxRegistrationCountryOptionsPlTypeIoss TaxRegistrationCountryOptionsPlType = "ioss" - TaxRegistrationCountryOptionsPlTypeOssNonUnion TaxRegistrationCountryOptionsPlType = "oss_non_union" - TaxRegistrationCountryOptionsPlTypeOssUnion TaxRegistrationCountryOptionsPlType = "oss_union" - TaxRegistrationCountryOptionsPlTypeStandard TaxRegistrationCountryOptionsPlType = "standard" + TaxRegistrationCountryOptionsPLTypeIoss TaxRegistrationCountryOptionsPLType = "ioss" + TaxRegistrationCountryOptionsPLTypeOssNonUnion TaxRegistrationCountryOptionsPLType = "oss_non_union" + TaxRegistrationCountryOptionsPLTypeOssUnion TaxRegistrationCountryOptionsPLType = "oss_union" + TaxRegistrationCountryOptionsPLTypeStandard TaxRegistrationCountryOptionsPLType = "standard" ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsPtStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsPTStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsPtStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsPTStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsPtStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsPtStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsPtStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsPtStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsPTStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsPTStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsPTStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsPTStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsPtType string +type TaxRegistrationCountryOptionsPTType string -// List of values that TaxRegistrationCountryOptionsPtType can take +// List of values that TaxRegistrationCountryOptionsPTType can take const ( - TaxRegistrationCountryOptionsPtTypeIoss TaxRegistrationCountryOptionsPtType = "ioss" - TaxRegistrationCountryOptionsPtTypeOssNonUnion TaxRegistrationCountryOptionsPtType = "oss_non_union" - TaxRegistrationCountryOptionsPtTypeOssUnion TaxRegistrationCountryOptionsPtType = "oss_union" - TaxRegistrationCountryOptionsPtTypeStandard TaxRegistrationCountryOptionsPtType = "standard" + TaxRegistrationCountryOptionsPTTypeIoss TaxRegistrationCountryOptionsPTType = "ioss" + TaxRegistrationCountryOptionsPTTypeOssNonUnion TaxRegistrationCountryOptionsPTType = "oss_non_union" + TaxRegistrationCountryOptionsPTTypeOssUnion TaxRegistrationCountryOptionsPTType = "oss_union" + TaxRegistrationCountryOptionsPTTypeStandard TaxRegistrationCountryOptionsPTType = "standard" ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsRoStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsROStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsRoStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsROStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsRoStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsRoStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsRoStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsRoStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsROStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsROStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsROStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsROStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsRoType string +type TaxRegistrationCountryOptionsROType string -// List of values that TaxRegistrationCountryOptionsRoType can take +// List of values that TaxRegistrationCountryOptionsROType can take const ( - TaxRegistrationCountryOptionsRoTypeIoss TaxRegistrationCountryOptionsRoType = "ioss" - TaxRegistrationCountryOptionsRoTypeOssNonUnion TaxRegistrationCountryOptionsRoType = "oss_non_union" - TaxRegistrationCountryOptionsRoTypeOssUnion TaxRegistrationCountryOptionsRoType = "oss_union" - TaxRegistrationCountryOptionsRoTypeStandard TaxRegistrationCountryOptionsRoType = "standard" + TaxRegistrationCountryOptionsROTypeIoss TaxRegistrationCountryOptionsROType = "ioss" + TaxRegistrationCountryOptionsROTypeOssNonUnion TaxRegistrationCountryOptionsROType = "oss_non_union" + TaxRegistrationCountryOptionsROTypeOssUnion TaxRegistrationCountryOptionsROType = "oss_union" + TaxRegistrationCountryOptionsROTypeStandard TaxRegistrationCountryOptionsROType = "standard" ) // Place of supply scheme used in an EU standard registration. @@ -619,23 +619,23 @@ const ( ) // Place of supply scheme used in an EU standard registration. -type TaxRegistrationCountryOptionsSkStandardPlaceOfSupplyScheme string +type TaxRegistrationCountryOptionsSKStandardPlaceOfSupplyScheme string -// List of values that TaxRegistrationCountryOptionsSkStandardPlaceOfSupplyScheme can take +// List of values that TaxRegistrationCountryOptionsSKStandardPlaceOfSupplyScheme can take const ( - TaxRegistrationCountryOptionsSkStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsSkStandardPlaceOfSupplyScheme = "small_seller" - TaxRegistrationCountryOptionsSkStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsSkStandardPlaceOfSupplyScheme = "standard" + TaxRegistrationCountryOptionsSKStandardPlaceOfSupplySchemeSmallSeller TaxRegistrationCountryOptionsSKStandardPlaceOfSupplyScheme = "small_seller" + TaxRegistrationCountryOptionsSKStandardPlaceOfSupplySchemeStandard TaxRegistrationCountryOptionsSKStandardPlaceOfSupplyScheme = "standard" ) // Type of registration in an EU country. -type TaxRegistrationCountryOptionsSkType string +type TaxRegistrationCountryOptionsSKType string -// List of values that TaxRegistrationCountryOptionsSkType can take +// List of values that TaxRegistrationCountryOptionsSKType can take const ( - TaxRegistrationCountryOptionsSkTypeIoss TaxRegistrationCountryOptionsSkType = "ioss" - TaxRegistrationCountryOptionsSkTypeOssNonUnion TaxRegistrationCountryOptionsSkType = "oss_non_union" - TaxRegistrationCountryOptionsSkTypeOssUnion TaxRegistrationCountryOptionsSkType = "oss_union" - TaxRegistrationCountryOptionsSkTypeStandard TaxRegistrationCountryOptionsSkType = "standard" + TaxRegistrationCountryOptionsSKTypeIoss TaxRegistrationCountryOptionsSKType = "ioss" + TaxRegistrationCountryOptionsSKTypeOssNonUnion TaxRegistrationCountryOptionsSKType = "oss_non_union" + TaxRegistrationCountryOptionsSKTypeOssUnion TaxRegistrationCountryOptionsSKType = "oss_union" + TaxRegistrationCountryOptionsSKTypeStandard TaxRegistrationCountryOptionsSKType = "standard" ) // Type of registration in the US. @@ -712,15 +712,15 @@ type TaxRegistrationCountryOptionsBeParams struct { } // Options for the standard registration. -type TaxRegistrationCountryOptionsBgStandardParams struct { +type TaxRegistrationCountryOptionsBGStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in BG. -type TaxRegistrationCountryOptionsBgParams struct { +type TaxRegistrationCountryOptionsBGParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsBgStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsBGStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } @@ -774,15 +774,15 @@ type TaxRegistrationCountryOptionsCzParams struct { } // Options for the standard registration. -type TaxRegistrationCountryOptionsDeStandardParams struct { +type TaxRegistrationCountryOptionsDEStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in DE. -type TaxRegistrationCountryOptionsDeParams struct { +type TaxRegistrationCountryOptionsDEParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsDeStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsDEStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } @@ -816,43 +816,43 @@ type TaxRegistrationCountryOptionsEeParams struct { } // Options for the standard registration. -type TaxRegistrationCountryOptionsEsStandardParams struct { +type TaxRegistrationCountryOptionsESStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in ES. -type TaxRegistrationCountryOptionsEsParams struct { +type TaxRegistrationCountryOptionsESParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsEsStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsESStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } // Options for the standard registration. -type TaxRegistrationCountryOptionsFiStandardParams struct { +type TaxRegistrationCountryOptionsFIStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in FI. -type TaxRegistrationCountryOptionsFiParams struct { +type TaxRegistrationCountryOptionsFIParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsFiStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsFIStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } // Options for the standard registration. -type TaxRegistrationCountryOptionsFrStandardParams struct { +type TaxRegistrationCountryOptionsFRStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in FR. -type TaxRegistrationCountryOptionsFrParams struct { +type TaxRegistrationCountryOptionsFRParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsFrStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsFRStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } @@ -884,29 +884,29 @@ type TaxRegistrationCountryOptionsHkParams struct { } // Options for the standard registration. -type TaxRegistrationCountryOptionsHrStandardParams struct { +type TaxRegistrationCountryOptionsHRStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in HR. -type TaxRegistrationCountryOptionsHrParams struct { +type TaxRegistrationCountryOptionsHRParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsHrStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsHRStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } // Options for the standard registration. -type TaxRegistrationCountryOptionsHuStandardParams struct { +type TaxRegistrationCountryOptionsHUStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in HU. -type TaxRegistrationCountryOptionsHuParams struct { +type TaxRegistrationCountryOptionsHUParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsHuStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsHUStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } @@ -932,15 +932,15 @@ type TaxRegistrationCountryOptionsIsParams struct { } // Options for the standard registration. -type TaxRegistrationCountryOptionsItStandardParams struct { +type TaxRegistrationCountryOptionsITStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in IT. -type TaxRegistrationCountryOptionsItParams struct { +type TaxRegistrationCountryOptionsITParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsItStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsITStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } @@ -952,15 +952,15 @@ type TaxRegistrationCountryOptionsJPParams struct { } // Options for the standard registration. -type TaxRegistrationCountryOptionsLtStandardParams struct { +type TaxRegistrationCountryOptionsLTStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in LT. -type TaxRegistrationCountryOptionsLtParams struct { +type TaxRegistrationCountryOptionsLTParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsLtStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsLTStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } @@ -980,43 +980,43 @@ type TaxRegistrationCountryOptionsLuParams struct { } // Options for the standard registration. -type TaxRegistrationCountryOptionsLvStandardParams struct { +type TaxRegistrationCountryOptionsLVStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in LV. -type TaxRegistrationCountryOptionsLvParams struct { +type TaxRegistrationCountryOptionsLVParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsLvStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsLVStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } // Options for the standard registration. -type TaxRegistrationCountryOptionsMtStandardParams struct { +type TaxRegistrationCountryOptionsMTStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in MT. -type TaxRegistrationCountryOptionsMtParams struct { +type TaxRegistrationCountryOptionsMTParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsMtStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsMTStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } // Options for the standard registration. -type TaxRegistrationCountryOptionsNlStandardParams struct { +type TaxRegistrationCountryOptionsNLStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in NL. -type TaxRegistrationCountryOptionsNlParams struct { +type TaxRegistrationCountryOptionsNLParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsNlStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsNLStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } @@ -1034,43 +1034,43 @@ type TaxRegistrationCountryOptionsNzParams struct { } // Options for the standard registration. -type TaxRegistrationCountryOptionsPlStandardParams struct { +type TaxRegistrationCountryOptionsPLStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in PL. -type TaxRegistrationCountryOptionsPlParams struct { +type TaxRegistrationCountryOptionsPLParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsPlStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsPLStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } // Options for the standard registration. -type TaxRegistrationCountryOptionsPtStandardParams struct { +type TaxRegistrationCountryOptionsPTStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in PT. -type TaxRegistrationCountryOptionsPtParams struct { +type TaxRegistrationCountryOptionsPTParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsPtStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsPTStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } // Options for the standard registration. -type TaxRegistrationCountryOptionsRoStandardParams struct { +type TaxRegistrationCountryOptionsROStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in RO. -type TaxRegistrationCountryOptionsRoParams struct { +type TaxRegistrationCountryOptionsROParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsRoStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsROStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } @@ -1110,19 +1110,25 @@ type TaxRegistrationCountryOptionsSiParams struct { } // Options for the standard registration. -type TaxRegistrationCountryOptionsSkStandardParams struct { +type TaxRegistrationCountryOptionsSKStandardParams struct { // Place of supply scheme used in an EU standard registration. PlaceOfSupplyScheme *string `form:"place_of_supply_scheme"` } // Options for the registration in SK. -type TaxRegistrationCountryOptionsSkParams struct { +type TaxRegistrationCountryOptionsSKParams struct { // Options for the standard registration. - Standard *TaxRegistrationCountryOptionsSkStandardParams `form:"standard"` + Standard *TaxRegistrationCountryOptionsSKStandardParams `form:"standard"` // Type of registration to be created in an EU country. Type *string `form:"type"` } +// Options for the local amusement tax registration. +type TaxRegistrationCountryOptionsUSLocalAmusementTaxParams struct { + // A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. + Jurisdiction *string `form:"jurisdiction"` +} + // Options for the local lease tax registration. type TaxRegistrationCountryOptionsUSLocalLeaseTaxParams struct { // A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. @@ -1131,6 +1137,8 @@ type TaxRegistrationCountryOptionsUSLocalLeaseTaxParams struct { // Options for the registration in US. type TaxRegistrationCountryOptionsUSParams struct { + // Options for the local amusement tax registration. + LocalAmusementTax *TaxRegistrationCountryOptionsUSLocalAmusementTaxParams `form:"local_amusement_tax"` // Options for the local lease tax registration. LocalLeaseTax *TaxRegistrationCountryOptionsUSLocalLeaseTaxParams `form:"local_lease_tax"` // Two-letter US state code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). @@ -1156,7 +1164,7 @@ type TaxRegistrationCountryOptionsParams struct { // Options for the registration in BE. Be *TaxRegistrationCountryOptionsBeParams `form:"be"` // Options for the registration in BG. - Bg *TaxRegistrationCountryOptionsBgParams `form:"bg"` + BG *TaxRegistrationCountryOptionsBGParams `form:"bg"` // Options for the registration in CA. Ca *TaxRegistrationCountryOptionsCaParams `form:"ca"` // Options for the registration in CH. @@ -1166,17 +1174,17 @@ type TaxRegistrationCountryOptionsParams struct { // Options for the registration in CZ. Cz *TaxRegistrationCountryOptionsCzParams `form:"cz"` // Options for the registration in DE. - De *TaxRegistrationCountryOptionsDeParams `form:"de"` + DE *TaxRegistrationCountryOptionsDEParams `form:"de"` // Options for the registration in DK. Dk *TaxRegistrationCountryOptionsDkParams `form:"dk"` // Options for the registration in EE. Ee *TaxRegistrationCountryOptionsEeParams `form:"ee"` // Options for the registration in ES. - Es *TaxRegistrationCountryOptionsEsParams `form:"es"` + ES *TaxRegistrationCountryOptionsESParams `form:"es"` // Options for the registration in FI. - Fi *TaxRegistrationCountryOptionsFiParams `form:"fi"` + FI *TaxRegistrationCountryOptionsFIParams `form:"fi"` // Options for the registration in FR. - Fr *TaxRegistrationCountryOptionsFrParams `form:"fr"` + FR *TaxRegistrationCountryOptionsFRParams `form:"fr"` // Options for the registration in GB. GB *TaxRegistrationCountryOptionsGBParams `form:"gb"` // Options for the registration in GR. @@ -1184,37 +1192,37 @@ type TaxRegistrationCountryOptionsParams struct { // Options for the registration in HK. Hk *TaxRegistrationCountryOptionsHkParams `form:"hk"` // Options for the registration in HR. - Hr *TaxRegistrationCountryOptionsHrParams `form:"hr"` + HR *TaxRegistrationCountryOptionsHRParams `form:"hr"` // Options for the registration in HU. - Hu *TaxRegistrationCountryOptionsHuParams `form:"hu"` + HU *TaxRegistrationCountryOptionsHUParams `form:"hu"` // Options for the registration in IE. Ie *TaxRegistrationCountryOptionsIeParams `form:"ie"` // Options for the registration in IS. Is *TaxRegistrationCountryOptionsIsParams `form:"is"` // Options for the registration in IT. - It *TaxRegistrationCountryOptionsItParams `form:"it"` + IT *TaxRegistrationCountryOptionsITParams `form:"it"` // Options for the registration in JP. JP *TaxRegistrationCountryOptionsJPParams `form:"jp"` // Options for the registration in LT. - Lt *TaxRegistrationCountryOptionsLtParams `form:"lt"` + LT *TaxRegistrationCountryOptionsLTParams `form:"lt"` // Options for the registration in LU. Lu *TaxRegistrationCountryOptionsLuParams `form:"lu"` // Options for the registration in LV. - Lv *TaxRegistrationCountryOptionsLvParams `form:"lv"` + LV *TaxRegistrationCountryOptionsLVParams `form:"lv"` // Options for the registration in MT. - Mt *TaxRegistrationCountryOptionsMtParams `form:"mt"` + MT *TaxRegistrationCountryOptionsMTParams `form:"mt"` // Options for the registration in NL. - Nl *TaxRegistrationCountryOptionsNlParams `form:"nl"` + NL *TaxRegistrationCountryOptionsNLParams `form:"nl"` // Options for the registration in NO. No *TaxRegistrationCountryOptionsNoParams `form:"no"` // Options for the registration in NZ. Nz *TaxRegistrationCountryOptionsNzParams `form:"nz"` // Options for the registration in PL. - Pl *TaxRegistrationCountryOptionsPlParams `form:"pl"` + PL *TaxRegistrationCountryOptionsPLParams `form:"pl"` // Options for the registration in PT. - Pt *TaxRegistrationCountryOptionsPtParams `form:"pt"` + PT *TaxRegistrationCountryOptionsPTParams `form:"pt"` // Options for the registration in RO. - Ro *TaxRegistrationCountryOptionsRoParams `form:"ro"` + RO *TaxRegistrationCountryOptionsROParams `form:"ro"` // Options for the registration in SE. Se *TaxRegistrationCountryOptionsSeParams `form:"se"` // Options for the registration in SG. @@ -1222,7 +1230,7 @@ type TaxRegistrationCountryOptionsParams struct { // Options for the registration in SI. Si *TaxRegistrationCountryOptionsSiParams `form:"si"` // Options for the registration in SK. - Sk *TaxRegistrationCountryOptionsSkParams `form:"sk"` + SK *TaxRegistrationCountryOptionsSKParams `form:"sk"` // Options for the registration in US. US *TaxRegistrationCountryOptionsUSParams `form:"us"` // Options for the registration in ZA. @@ -1280,14 +1288,14 @@ type TaxRegistrationCountryOptionsBe struct { // Type of registration in an EU country. Type TaxRegistrationCountryOptionsBeType `json:"type"` } -type TaxRegistrationCountryOptionsBgStandard struct { +type TaxRegistrationCountryOptionsBGStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsBgStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsBGStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsBg struct { - Standard *TaxRegistrationCountryOptionsBgStandard `json:"standard"` +type TaxRegistrationCountryOptionsBG struct { + Standard *TaxRegistrationCountryOptionsBGStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsBgType `json:"type"` + Type TaxRegistrationCountryOptionsBGType `json:"type"` } type TaxRegistrationCountryOptionsCaProvinceStandard struct { // Two-letter CA province code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). @@ -1320,14 +1328,14 @@ type TaxRegistrationCountryOptionsCz struct { // Type of registration in an EU country. Type TaxRegistrationCountryOptionsCzType `json:"type"` } -type TaxRegistrationCountryOptionsDeStandard struct { +type TaxRegistrationCountryOptionsDEStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsDeStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsDEStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsDe struct { - Standard *TaxRegistrationCountryOptionsDeStandard `json:"standard"` +type TaxRegistrationCountryOptionsDE struct { + Standard *TaxRegistrationCountryOptionsDEStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsDeType `json:"type"` + Type TaxRegistrationCountryOptionsDEType `json:"type"` } type TaxRegistrationCountryOptionsDkStandard struct { // Place of supply scheme used in an EU standard registration. @@ -1347,32 +1355,32 @@ type TaxRegistrationCountryOptionsEe struct { // Type of registration in an EU country. Type TaxRegistrationCountryOptionsEeType `json:"type"` } -type TaxRegistrationCountryOptionsEsStandard struct { +type TaxRegistrationCountryOptionsESStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsEsStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsESStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsEs struct { - Standard *TaxRegistrationCountryOptionsEsStandard `json:"standard"` +type TaxRegistrationCountryOptionsES struct { + Standard *TaxRegistrationCountryOptionsESStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsEsType `json:"type"` + Type TaxRegistrationCountryOptionsESType `json:"type"` } -type TaxRegistrationCountryOptionsFiStandard struct { +type TaxRegistrationCountryOptionsFIStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsFiStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsFIStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsFi struct { - Standard *TaxRegistrationCountryOptionsFiStandard `json:"standard"` +type TaxRegistrationCountryOptionsFI struct { + Standard *TaxRegistrationCountryOptionsFIStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsFiType `json:"type"` + Type TaxRegistrationCountryOptionsFIType `json:"type"` } -type TaxRegistrationCountryOptionsFrStandard struct { +type TaxRegistrationCountryOptionsFRStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsFrStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsFRStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsFr struct { - Standard *TaxRegistrationCountryOptionsFrStandard `json:"standard"` +type TaxRegistrationCountryOptionsFR struct { + Standard *TaxRegistrationCountryOptionsFRStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsFrType `json:"type"` + Type TaxRegistrationCountryOptionsFRType `json:"type"` } type TaxRegistrationCountryOptionsGB struct { // Type of registration in `country`. @@ -1391,23 +1399,23 @@ type TaxRegistrationCountryOptionsHk struct { // Type of registration in `country`. Type TaxRegistrationCountryOptionsHkType `json:"type"` } -type TaxRegistrationCountryOptionsHrStandard struct { +type TaxRegistrationCountryOptionsHRStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsHrStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsHRStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsHr struct { - Standard *TaxRegistrationCountryOptionsHrStandard `json:"standard"` +type TaxRegistrationCountryOptionsHR struct { + Standard *TaxRegistrationCountryOptionsHRStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsHrType `json:"type"` + Type TaxRegistrationCountryOptionsHRType `json:"type"` } -type TaxRegistrationCountryOptionsHuStandard struct { +type TaxRegistrationCountryOptionsHUStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsHuStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsHUStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsHu struct { - Standard *TaxRegistrationCountryOptionsHuStandard `json:"standard"` +type TaxRegistrationCountryOptionsHU struct { + Standard *TaxRegistrationCountryOptionsHUStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsHuType `json:"type"` + Type TaxRegistrationCountryOptionsHUType `json:"type"` } type TaxRegistrationCountryOptionsIeStandard struct { // Place of supply scheme used in an EU standard registration. @@ -1422,27 +1430,27 @@ type TaxRegistrationCountryOptionsIs struct { // Type of registration in `country`. Type TaxRegistrationCountryOptionsIsType `json:"type"` } -type TaxRegistrationCountryOptionsItStandard struct { +type TaxRegistrationCountryOptionsITStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsItStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsITStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsIt struct { - Standard *TaxRegistrationCountryOptionsItStandard `json:"standard"` +type TaxRegistrationCountryOptionsIT struct { + Standard *TaxRegistrationCountryOptionsITStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsItType `json:"type"` + Type TaxRegistrationCountryOptionsITType `json:"type"` } type TaxRegistrationCountryOptionsJP struct { // Type of registration in `country`. Type TaxRegistrationCountryOptionsJPType `json:"type"` } -type TaxRegistrationCountryOptionsLtStandard struct { +type TaxRegistrationCountryOptionsLTStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsLtStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsLTStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsLt struct { - Standard *TaxRegistrationCountryOptionsLtStandard `json:"standard"` +type TaxRegistrationCountryOptionsLT struct { + Standard *TaxRegistrationCountryOptionsLTStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsLtType `json:"type"` + Type TaxRegistrationCountryOptionsLTType `json:"type"` } type TaxRegistrationCountryOptionsLuStandard struct { // Place of supply scheme used in an EU standard registration. @@ -1453,32 +1461,32 @@ type TaxRegistrationCountryOptionsLu struct { // Type of registration in an EU country. Type TaxRegistrationCountryOptionsLuType `json:"type"` } -type TaxRegistrationCountryOptionsLvStandard struct { +type TaxRegistrationCountryOptionsLVStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsLvStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsLVStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsLv struct { - Standard *TaxRegistrationCountryOptionsLvStandard `json:"standard"` +type TaxRegistrationCountryOptionsLV struct { + Standard *TaxRegistrationCountryOptionsLVStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsLvType `json:"type"` + Type TaxRegistrationCountryOptionsLVType `json:"type"` } -type TaxRegistrationCountryOptionsMtStandard struct { +type TaxRegistrationCountryOptionsMTStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsMtStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsMTStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsMt struct { - Standard *TaxRegistrationCountryOptionsMtStandard `json:"standard"` +type TaxRegistrationCountryOptionsMT struct { + Standard *TaxRegistrationCountryOptionsMTStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsMtType `json:"type"` + Type TaxRegistrationCountryOptionsMTType `json:"type"` } -type TaxRegistrationCountryOptionsNlStandard struct { +type TaxRegistrationCountryOptionsNLStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsNlStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsNLStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsNl struct { - Standard *TaxRegistrationCountryOptionsNlStandard `json:"standard"` +type TaxRegistrationCountryOptionsNL struct { + Standard *TaxRegistrationCountryOptionsNLStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsNlType `json:"type"` + Type TaxRegistrationCountryOptionsNLType `json:"type"` } type TaxRegistrationCountryOptionsNo struct { // Type of registration in `country`. @@ -1488,32 +1496,32 @@ type TaxRegistrationCountryOptionsNz struct { // Type of registration in `country`. Type TaxRegistrationCountryOptionsNzType `json:"type"` } -type TaxRegistrationCountryOptionsPlStandard struct { +type TaxRegistrationCountryOptionsPLStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsPlStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsPLStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsPl struct { - Standard *TaxRegistrationCountryOptionsPlStandard `json:"standard"` +type TaxRegistrationCountryOptionsPL struct { + Standard *TaxRegistrationCountryOptionsPLStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsPlType `json:"type"` + Type TaxRegistrationCountryOptionsPLType `json:"type"` } -type TaxRegistrationCountryOptionsPtStandard struct { +type TaxRegistrationCountryOptionsPTStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsPtStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsPTStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsPt struct { - Standard *TaxRegistrationCountryOptionsPtStandard `json:"standard"` +type TaxRegistrationCountryOptionsPT struct { + Standard *TaxRegistrationCountryOptionsPTStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsPtType `json:"type"` + Type TaxRegistrationCountryOptionsPTType `json:"type"` } -type TaxRegistrationCountryOptionsRoStandard struct { +type TaxRegistrationCountryOptionsROStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsRoStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsROStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsRo struct { - Standard *TaxRegistrationCountryOptionsRoStandard `json:"standard"` +type TaxRegistrationCountryOptionsRO struct { + Standard *TaxRegistrationCountryOptionsROStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsRoType `json:"type"` + Type TaxRegistrationCountryOptionsROType `json:"type"` } type TaxRegistrationCountryOptionsSeStandard struct { // Place of supply scheme used in an EU standard registration. @@ -1537,21 +1545,26 @@ type TaxRegistrationCountryOptionsSi struct { // Type of registration in an EU country. Type TaxRegistrationCountryOptionsSiType `json:"type"` } -type TaxRegistrationCountryOptionsSkStandard struct { +type TaxRegistrationCountryOptionsSKStandard struct { // Place of supply scheme used in an EU standard registration. - PlaceOfSupplyScheme TaxRegistrationCountryOptionsSkStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` + PlaceOfSupplyScheme TaxRegistrationCountryOptionsSKStandardPlaceOfSupplyScheme `json:"place_of_supply_scheme"` } -type TaxRegistrationCountryOptionsSk struct { - Standard *TaxRegistrationCountryOptionsSkStandard `json:"standard"` +type TaxRegistrationCountryOptionsSK struct { + Standard *TaxRegistrationCountryOptionsSKStandard `json:"standard"` // Type of registration in an EU country. - Type TaxRegistrationCountryOptionsSkType `json:"type"` + Type TaxRegistrationCountryOptionsSKType `json:"type"` +} +type TaxRegistrationCountryOptionsUSLocalAmusementTax struct { + // A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. + Jurisdiction string `json:"jurisdiction"` } type TaxRegistrationCountryOptionsUSLocalLeaseTax struct { // A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Jurisdiction string `json:"jurisdiction"` } type TaxRegistrationCountryOptionsUS struct { - LocalLeaseTax *TaxRegistrationCountryOptionsUSLocalLeaseTax `json:"local_lease_tax"` + LocalAmusementTax *TaxRegistrationCountryOptionsUSLocalAmusementTax `json:"local_amusement_tax"` + LocalLeaseTax *TaxRegistrationCountryOptionsUSLocalLeaseTax `json:"local_lease_tax"` // Two-letter US state code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). State string `json:"state"` // Type of registration in the US. @@ -1566,40 +1579,40 @@ type TaxRegistrationCountryOptions struct { At *TaxRegistrationCountryOptionsAt `json:"at"` Au *TaxRegistrationCountryOptionsAu `json:"au"` Be *TaxRegistrationCountryOptionsBe `json:"be"` - Bg *TaxRegistrationCountryOptionsBg `json:"bg"` + BG *TaxRegistrationCountryOptionsBG `json:"bg"` Ca *TaxRegistrationCountryOptionsCa `json:"ca"` Ch *TaxRegistrationCountryOptionsCh `json:"ch"` Cy *TaxRegistrationCountryOptionsCy `json:"cy"` Cz *TaxRegistrationCountryOptionsCz `json:"cz"` - De *TaxRegistrationCountryOptionsDe `json:"de"` + DE *TaxRegistrationCountryOptionsDE `json:"de"` Dk *TaxRegistrationCountryOptionsDk `json:"dk"` Ee *TaxRegistrationCountryOptionsEe `json:"ee"` - Es *TaxRegistrationCountryOptionsEs `json:"es"` - Fi *TaxRegistrationCountryOptionsFi `json:"fi"` - Fr *TaxRegistrationCountryOptionsFr `json:"fr"` + ES *TaxRegistrationCountryOptionsES `json:"es"` + FI *TaxRegistrationCountryOptionsFI `json:"fi"` + FR *TaxRegistrationCountryOptionsFR `json:"fr"` GB *TaxRegistrationCountryOptionsGB `json:"gb"` Gr *TaxRegistrationCountryOptionsGr `json:"gr"` Hk *TaxRegistrationCountryOptionsHk `json:"hk"` - Hr *TaxRegistrationCountryOptionsHr `json:"hr"` - Hu *TaxRegistrationCountryOptionsHu `json:"hu"` + HR *TaxRegistrationCountryOptionsHR `json:"hr"` + HU *TaxRegistrationCountryOptionsHU `json:"hu"` Ie *TaxRegistrationCountryOptionsIe `json:"ie"` Is *TaxRegistrationCountryOptionsIs `json:"is"` - It *TaxRegistrationCountryOptionsIt `json:"it"` + IT *TaxRegistrationCountryOptionsIT `json:"it"` JP *TaxRegistrationCountryOptionsJP `json:"jp"` - Lt *TaxRegistrationCountryOptionsLt `json:"lt"` + LT *TaxRegistrationCountryOptionsLT `json:"lt"` Lu *TaxRegistrationCountryOptionsLu `json:"lu"` - Lv *TaxRegistrationCountryOptionsLv `json:"lv"` - Mt *TaxRegistrationCountryOptionsMt `json:"mt"` - Nl *TaxRegistrationCountryOptionsNl `json:"nl"` + LV *TaxRegistrationCountryOptionsLV `json:"lv"` + MT *TaxRegistrationCountryOptionsMT `json:"mt"` + NL *TaxRegistrationCountryOptionsNL `json:"nl"` No *TaxRegistrationCountryOptionsNo `json:"no"` Nz *TaxRegistrationCountryOptionsNz `json:"nz"` - Pl *TaxRegistrationCountryOptionsPl `json:"pl"` - Pt *TaxRegistrationCountryOptionsPt `json:"pt"` - Ro *TaxRegistrationCountryOptionsRo `json:"ro"` + PL *TaxRegistrationCountryOptionsPL `json:"pl"` + PT *TaxRegistrationCountryOptionsPT `json:"pt"` + RO *TaxRegistrationCountryOptionsRO `json:"ro"` Se *TaxRegistrationCountryOptionsSe `json:"se"` Sg *TaxRegistrationCountryOptionsSg `json:"sg"` Si *TaxRegistrationCountryOptionsSi `json:"si"` - Sk *TaxRegistrationCountryOptionsSk `json:"sk"` + SK *TaxRegistrationCountryOptionsSK `json:"sk"` US *TaxRegistrationCountryOptionsUS `json:"us"` Za *TaxRegistrationCountryOptionsZa `json:"za"` } diff --git a/tax_settings.go b/tax_settings.go index 2c81f0851f..14797995d0 100644 --- a/tax_settings.go +++ b/tax_settings.go @@ -16,14 +16,6 @@ const ( TaxSettingsDefaultsTaxBehaviorInferredByCurrency TaxSettingsDefaultsTaxBehavior = "inferred_by_currency" ) -// The role of this location address. -type TaxSettingsLocationRole string - -// List of values that TaxSettingsLocationRole can take -const ( - TaxSettingsLocationRoleHeadOffice TaxSettingsLocationRole = "head_office" -) - // The `active` status indicates you have all required settings to calculate tax. A status can transition out of `active` when new required settings are introduced. type TaxSettingsStatus string @@ -40,8 +32,6 @@ type TaxSettingsParams struct { Defaults *TaxSettingsDefaultsParams `form:"defaults"` // The place where your business is located. HeadOffice *TaxSettingsHeadOfficeParams `form:"head_office"` - // The deprecated places where your business is located. - Locations []*TaxSettingsLocationParams `form:"locations"` } // Default configuration to be used on Stripe Tax calculations. @@ -57,14 +47,6 @@ type TaxSettingsHeadOfficeParams struct { // The location of the business for tax purposes. Address *AddressParams `form:"address"` } - -// The deprecated places where your business is located. -type TaxSettingsLocationParams struct { - // The location of the business for tax purposes. - Address *AddressParams `form:"address"` - // The role of this location address. - Role *string `form:"role"` -} type TaxSettingsDefaults struct { // Default [tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#tax-behavior) used to specify whether the price is considered inclusive of taxes or exclusive of taxes. If the item's price has a tax behavior set, it will take precedence over the default tax behavior. TaxBehavior TaxSettingsDefaultsTaxBehavior `json:"tax_behavior"` @@ -76,13 +58,6 @@ type TaxSettingsDefaults struct { type TaxSettingsHeadOffice struct { Address *Address `json:"address"` } - -// The deprecated places where your business is located. -type TaxSettingsLocation struct { - Address *Address `json:"address"` - // The role of this location address. - Role TaxSettingsLocationRole `json:"role"` -} type TaxSettingsStatusDetailsActive struct{} type TaxSettingsStatusDetailsPending struct { // The list of missing fields that are required to perform calculations. It includes the entry `head_office` when the status is `pending`. It is recommended to set the optional values even if they aren't listed as required for calculating taxes. Calculations can fail if missing fields aren't explicitly provided on every call. @@ -103,8 +78,6 @@ type TaxSettings struct { HeadOffice *TaxSettingsHeadOffice `json:"head_office"` // Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. Livemode bool `json:"livemode"` - // The deprecated places where your business is located. - Locations []*TaxSettingsLocation `json:"locations"` // String representing the object's type. Objects of the same type share the same value. Object string `json:"object"` // The `active` status indicates you have all required settings to calculate tax. A status can transition out of `active` when new required settings are introduced.